Skip to content
emptyenemyPublic

About

AIR SDK Manager as a command-line tool. One native binary for Windows, macOS, and Linux.

Topics

Resources

Contributing

Stars

1 star

Watchers

0 watching

Forks

Repository files navigation

asm

AIR SDK versions, managed from your terminal.

Latest release Build status Windows, macOS and Linux Go version MIT license

Website · Install · Quick start · Commands · Releases

asm update finds a newer 51.3 build and announces 51.4.1.1, asm install 51.4 downloads and installs it with a progress bar, and asm list shows both SDKs with their paths.

asm finds, installs, updates and removes AIR SDK builds. It is one native binary for Windows, macOS and Linux, and it works with the settings AIR SDK Manager already keeps: no runtime, no GUI, no admin rights.

Why asm

  • Short versions. asm install 51.4 picks the newest stable 51.4 build. An exact build such as 51.4.1.1, or latest, works too.
  • One set of settings with AIR SDK Manager. asm keeps its settings in ~/.airsdk/airsdkmanager.cfg, the manager's own file, so both tools see the same SDKs. Nothing to set up: asm fills in what is missing and leaves the manager's lines alone.
  • Downloads that survive. A dropped connection resumes from the bytes already on disk, on the next attempt or on the next run.
  • Verified before unpacking. Every archive is checked against its published size and SHA-256 before a single file is extracted.
  • Three sources. When the official API does not answer, asm falls back to the announcement archive and the shockpkg mirror, and says which one it used.
  • Safe updates. The old SDK stays until the new one is in place. The path, adt.cfg and adt.lic carry over, so your tools keep working.
  • Recoverable. Closed the terminal mid-install? asm clean removes the leftovers and puts a half-replaced SDK back.

Install

Windows, in PowerShell:

irm https://raw.githubusercontent.com/emptyenemy/asm/main/install.ps1 | iex

macOS and Linux:

curl -fsSL https://raw.githubusercontent.com/emptyenemy/asm/main/install.sh | sh

The installers pick the native binary for your machine, check it against the release's SHA256SUMS, and stop rather than overwrite an unrelated command called asm.

  • Windows: asm.exe goes to %LOCALAPPDATA%\Programs\asm, on your user PATH. It works in the same PowerShell session; other open terminals need a restart.
  • macOS and Linux: asm goes to ~/.local/bin, which is added to .zshrc, .bashrc, .bash_profile or .profile for your shell. Open a new terminal, or source the profile the installer names.
Installer options
Windows, install.ps1 macOS and Linux, install.sh Effect
-Version 1.0.1 ASM_VERSION=1.0.1 Install that asm release instead of the latest.
-InstallDirectory C:\Tools\asm ASM_INSTALL_DIR=/absolute/path Install somewhere else.
-NoPath ASM_NO_PATH=1 Leave PATH and shell profiles unchanged.
-ArchiveDirectory DIR ASM_ARCHIVE_DIR=DIR Install from local release archives. Needs an explicit version and a directory with the matching archive and SHA256SUMS.

PowerShell parameters need the script downloaded first:

./install.ps1 -Version 1.0.1 -InstallDirectory C:\Tools\asm

Shell variables go in front of sh:

curl -fsSL https://raw.githubusercontent.com/emptyenemy/asm/main/install.sh | ASM_NO_PATH=1 sh

Existing PATH entries are kept, and a repeated install replaces only an installation owned by asm. Archives, staging files and previous asm binaries are removed after a successful install. The installer sets up the asm command only; where SDKs go still comes from the AIR SDK Manager settings.

Build from source

With Go 1.27.1 or newer:

go build .
./asm --version

In PowerShell, run ./asm.exe. Add the folder to PATH to run asm from anywhere. A released binary is smaller, because the release workflow strips the symbol table and debug information and disables cgo; AGENTS.md has the exact command.

Quick start

asm search 51.4      # stable releases in the 51.4 branch
asm install 51.4     # the newest of them
asm list             # what is installed, and where
asm update           # newer builds for what you have

There is nothing to configure first. asm shares its settings with AIR SDK Manager in ~/.airsdk/airsdkmanager.cfg (%USERPROFILE%\.airsdk\airsdkmanager.cfg on Windows):

  • SDK folder. If the manager is set up, asm uses its folder. Otherwise the first run creates the file with AIR_SDKS set to ~/sdks/air, the folder the AIR SDK installation guides recommend, and says so.
  • License. The first install shows where to read the AIR SDK license and asks you to accept it. A yes is saved as HAS_ACCEPTED_LICENSE=true, the same line the manager writes, so neither tool asks again. In scripts and CI, where nobody can answer, pass --accept-license; it covers that one run and changes nothing on disk.

To keep SDKs elsewhere, set the folder before the first install:

AIR_SDKS=D:\AIRSDK

asm only ever adds or updates these two lines. Comments, other settings and the file's line endings stay as the manager left them.

Commands

Command What it does
asm list, asm ls List installed SDKs and their paths, newest first.
asm search [VERSION] List stable releases, newest first. A version narrows the list.
asm install [VERSION] Install a branch such as 51.4, an exact build, or latest.
asm update Show newer builds of installed SDKs, and a newer branch if there is one.
asm update [VERSION] Update the installed SDKs that match.
asm update --all Update every installed SDK that has a newer build.
asm update [VERSION] --check Preview the updates for matching SDKs.
asm update --all --check Preview every update and the new-branch notice.
asm uninstall [VERSION], asm remove [VERSION] Remove one installed SDK, chosen by exact build or an unambiguous prefix.
asm clean Remove what an interrupted install or update left behind.
asm clean --check List what clean would change, without changing it.
asm help [COMMAND] Show help for asm or one command.
asm --version, asm -v Print the asm version, such as 1.0.1.

Square brackets mark a value you supply: type 51.4, not [51.4]. install and uninstall need a version; search, update and help take one optionally. asm --help, asm -h and asm install --help work too.

Errors and warnings go to stderr. A successful command exits with 0, an error with 1. Unknown commands and unexpected arguments are rejected.

How each command behaves

list: what is installed
asm list

Only the immediate subfolders of AIR_SDKS are examined, as in AIR SDK Manager. Folder names do not matter: the version comes from air-sdk-description.xml, where <version>51.3.4</version> and <build>3</build> make 51.3.4.3. A four-component <version> is read as is.

Versions are sorted numerically, newest first. Folders without a description are skipped, and an unreadable description produces a warning. An SDK folder that is empty, or not created yet, prints a message and exits with 0.

search: what is available
asm search
asm search 51.4
asm search 51.4.1.1

Filters match whole version components: 51.4 does not match 51.40. A four-component filter needs an exact match. Results are full build numbers, newest first; no match prints a message and exits with 0.

The release list comes from the official AIR SDK API, then from the announcement archive, then from the catalog AIR SDK Manager saved in airsdkmanager.db and its airsdkmanager.db.backup* copies, newest first. A warning names the source used when the first one fails; a saved catalog may be out of date. Failing to get any usable list is an error.

The announcement archive has fresh releases but can miss older builds that had no announcement of their own. Beta, alpha and preview entries are skipped by title, and the previews 51.0.0.2 and 51.0.0.4, titled as releases, are skipped by number.

install: add an SDK
asm install 51.4
asm install 51.4.1.1
asm install latest
asm install 51.4 --accept-license

51, 51.4 and 51.4.1 resolve to the newest matching stable build, and latest to the newest stable build overall; all four components are compared numerically. An exact version goes straight to the download source, so builds without an announcement can be installed too. A version that does not exist is an error; asm never substitutes a different build.

51.4.1.1 installs into AIR_SDKS\AIRSDK_51.4.1.1, creating AIR_SDKS if needed. A build that is already installed is recognised by its description, whatever its folder is called, and is not downloaded again. A destination that already holds other files is refused. Installing does not change the SDK your projects use or PATH.

The SDK is assembled in a hidden staging folder inside AIR_SDKS and moved into place in one step. Downloads come from the official API first and from the shockpkg mirror if that fails at any point. An interrupted download is kept in AIR_SDKS/.asm-partial, named after its expected SHA-256, and continues from the stored bytes: up to four attempts with 1, 2 and 4 second pauses, and a transfer that receives nothing for 30 seconds is restarted. Partial files that fail verification, and ones older than seven days, are deleted.

Each archive is checked for size and SHA-256 before it is extracted, and every extracted path must stay inside the SDK folder. On macOS and Linux, executable permissions and safe relative symbolic links are kept. Linux SDKs run configure_linux.sh when it is present, and ARM64 requires it. On macOS the quarantine flag is removed if present, without asking for an administrator password.

update: newer builds of what you have
asm update
asm update 51.3 --check
asm update 51.3
asm update 51.3.4.1
asm update --all
asm update --all --accept-license

Without arguments, asm lists installed SDKs that have a newer build, with paths, and changes nothing. It also announces the newest stable release when it is newer than every installed SDK and its branch is not installed:

Installed SDKs are up to date.

New AIR SDK available: 51.4.1.1
Install: asm install 51.4

The notice also appears with --check, --all and --all --check, and disappears once that branch is installed. An empty SDK folder gets a suggestion to install the newest stable version. A version argument narrows the overview to the installed SDKs it matches.

--all applies every available update. A version selects installed SDKs by prefix; a full number selects the installation, not the target build. --check can go before or after the version. A version and --all cannot be combined.

As in AIR SDK Manager, an update changes only the fourth component: 51.3.4.1 becomes 51.3.4.3, while 51.3.3 and 51.3.4 stay separate SDKs. New branches are installed with install. The SDK keeps its path, lib/adt.cfg and lib/adt.lic, so existing tool paths stay valid. The old SDK is renamed aside until the new one is in place and is restored if the swap fails.

No matching installation is an error that suggests asm list; no available update is a success. --all updates SDKs one after another and stops at the first error, keeping the updates already finished.

uninstall: remove an SDK
asm uninstall 51.4
asm uninstall 51.3.4.3
asm remove 51.4.1.1

An exact build or a prefix must match exactly one installed SDK. An ambiguous prefix lists the matching versions and paths and deletes nothing; no match is an error too. latest, --all and several versions in one command are not supported.

The SDK folder is deleted directly, without a backup. asm first checks its description and that it lies inside AIR_SDKS, refuses symbolic-link folders, and takes the same lock as install and update. Manager settings, other SDKs and PATH stay unchanged. If files are locked or removal fails, the error names the folder that needs attention.

clean: after an interrupted run

Ctrl+C stops an operation and cleans up what it staged. Closing the terminal, pressing Ctrl+C twice, killing the process or losing power skips that cleanup, and asm clean is the way back:

Leftover What clean does
.asm-partial Removes incomplete downloads. The next install starts over instead of resuming.
.asm-install-*, .asm-update-* Removes staging folders from an interrupted install or update.
.asm-old-* An SDK renamed aside during an update: moved back when its build is no longer installed, removed when it is.
An empty version folder Removed, since it would block installing that version again.

clean takes the same lock as install and update, so it refuses to run beside them. Installed SDKs, settings and unrelated files are never touched. A saved SDK whose description cannot be read is reported and left in place. clean --check prints the same report and changes nothing.

Terminal output

In an interactive terminal every answer sits between two blank lines, indented by two columns. The indigo accent (#818CF8) marks headings, versions, results and the command to run next; labels and side notes are muted, and warnings and errors are marked in amber and red. Versions and paths line up in columns, and narrow terminals get stacked entries and wrapped paths. Requests show a spinner; downloads show a bar with the bytes transferred, the percentage when the size is known, and the average speed. Progress goes to stderr and is cleared when it finishes.

NO_COLOR turns colors off and keeps the animation. TERM=dumb or redirecting either output stream turns off both, and search results become one full version per line, without headings or suggestions. --version prints only the version, which makes it easy to use in scripts. The installers follow the same rules.

Limitations

  • Windows on ARM is not supported. There is no native Windows ARM64 AIR SDK, so the installer stops with that message.
  • The live download service is not verified on every host yet. Commands, settings handling and SDK assembly are covered by tests on all five builds, but downloading a real SDK has not been checked everywhere. If something breaks, open an issue with the command and its output.
  • The AIR SDK license is yours to accept. asm downloads nothing until you accept it: when asm asks, in the manager settings, or with --accept-license for a single run.

Contributing

Bug reports and pull requests are welcome. CONTRIBUTING.md gets you from clone to passing tests in a minute and shows where things live; AGENTS.md holds the file-by-file map, the release build, and the notes on the AIR SDK services asm talks to.

License

MIT, see LICENSE. asm is an independent project, not an official AIR SDK tool. The AIR SDK itself is a separate product under its own license.

About

AIR SDK Manager as a command-line tool. One native binary for Windows, macOS, and Linux.

Topics

Resources

Contributing

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages