Skip to content

mas

Lists, installs and upgrades App Store apps — the missing half of a scripted machine setup.

Homebrew formula

What it does

mas drives the Mac App Store: list what is installed with version numbers, search the store, install by numeric ID, and upgrade everything outdated.

mas list                    # installed apps with their IDs
mas outdated
mas upgrade
mas install 497799835       # Xcode, by ID
mas search "color picker"

Why it matters

A setup script can install Homebrew formulae and casks, but App Store apps used to require clicking. mas closes that gap, so a Brewfile plus a short mas install list reproduces a machine’s software completely:

brew bundle dump --describe    # write a Brewfile from what is installed
mas list | awk '{print $1}'    # the App Store half

Notes

Apps must already be associated with the signed-in Apple Account — mas cannot make a first purchase, only install something the account owns. Signing in has to happen in the App Store app itself.

Alternative to

AlternativeTypeTrade-off
The App Store appBuilt inThe only way to make a first purchase or sign in
Homebrew casksOpen sourceFor anything that also ships outside the App Store; mas is the fallback, not the default
MDM (Jamf, Kandji, Mosyle)PaidHow this is actually solved for fleets

Install

brew install mas

Links

This post is licensed under CC BY 4.0 by the author.
Last updated on