BSD Punk: Install Mac App Store Applications from the command line.
source link: http://bsdpunk.blogspot.com/2017/10/install-mac-app-store-applications-from.html
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
Install Mac App Store Applications from the command line.
I recently, and hastily made some scripts for recovery of a mac, as I did a clean install of High Sierra (Which I don't recommend for right now, I have some problems with it, that I feel will easily be remedied as time passes. Mainly some issues with messages).
But I found a handy location, called mac that let's you install Mac App Store Lications from the command Line.
If we learned anything today, it's that Lication is the best way to shorten the word Application.
#Have the full Xcode installed for this to work
#Install mas
brew install mas
#Declare your lications, with line breaks in between
LICATIONS="Pages\nKeynote\nNumbers\nGarageBand\nKindle"
#for loop, looping through lications
for i in $(echo -e $LICATIONS)
do
#Install the lication, by finding and printing it's corresponding number, this is how mas works
mas install $(mas search $i | ggrep -P "^\d+ $i$" | awk '{print $1}') &
# Note that I eneded this line, with an ampersand switching it to the background, as to install in Parallel
#If you feel like it's doing to many at one time, remove the ampersand
done
If you want to be this handy at bash, you can check out this book.
Recommend
About Joyk
Aggregate valuable and interesting links.
Joyk means Joy of geeK