From 44e9f61bded005eb1a42b26b881c6e67c01fc8dc Mon Sep 17 00:00:00 2001 From: Bruno 21 Date: Tue, 15 Jan 2019 22:06:50 +0100 Subject: [PATCH] make-brew-installer.sh MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Pour mas, ajout du nom de l’application en commentaire --- make-brew-installer.sh | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/make-brew-installer.sh b/make-brew-installer.sh index d996d94..a198a0e 100755 --- a/make-brew-installer.sh +++ b/make-brew-installer.sh @@ -134,7 +134,15 @@ fi if [ "$mas" -eq 1 ]; then echo -e "\n# Mac App Store applications list.\n" >> brew-install.sh echo -e "šŸ Get Mac App Store \033[3m\033[93mapplications\033[0m list" - mas list | awk '{print $1}' | sed -e 's/^/mas install /' >> brew-install.sh + #mas list | awk '{print $1}' | sed -e 's/^/mas install /' >> brew-install.sh + dependencies=$(mas list) + while read -r line; do + number=$(echo "$line" | awk '{print $1}') + name=$(echo "$line" | awk -F "(" '{print $1}' | awk {'first = $1; $1=""; print $0'} | sed 's/^ //g') + echo "#$name" >> brew-install.sh + echo "mas install $number" >> brew-install.sh + echo " " >> brew-install.sh + done <<< "$dependencies" fi chmod +x brew-install.sh