mirror of
https://github.com/mtan93/Installomator.git
synced 2026-03-08 05:31:53 +00:00
added tbz support and TextMate
This commit is contained in:
1
.gitignore
vendored
1
.gitignore
vendored
@@ -7,5 +7,6 @@ scratch/
|
|||||||
*.dmg
|
*.dmg
|
||||||
*.zip
|
*.zip
|
||||||
*.app
|
*.app
|
||||||
|
*.tbz
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -229,6 +229,12 @@ case $identifier in
|
|||||||
downloadURL="http://get.videolan.org/vlc/3.0.8/macosx/vlc-3.0.8.dmg"
|
downloadURL="http://get.videolan.org/vlc/3.0.8/macosx/vlc-3.0.8.dmg"
|
||||||
expectedTeamID="75GAHG3SZQ"
|
expectedTeamID="75GAHG3SZQ"
|
||||||
;;
|
;;
|
||||||
|
textmate)
|
||||||
|
name="TextMate"
|
||||||
|
type="tbz"
|
||||||
|
downloadURL="https://api.textmate.org/downloads/release?os=10.12"
|
||||||
|
expectedTeamID="45TL96F76G"
|
||||||
|
;;
|
||||||
|
|
||||||
|
|
||||||
microsoftoffice365)
|
microsoftoffice365)
|
||||||
@@ -545,7 +551,7 @@ installFromPKG() {
|
|||||||
installFromZIP() {
|
installFromZIP() {
|
||||||
# unzip the archive
|
# unzip the archive
|
||||||
echo "Unzipping $archiveName"
|
echo "Unzipping $archiveName"
|
||||||
unzip -o -qq "$archiveName"
|
tar -xf "$archiveName"
|
||||||
|
|
||||||
installAppWithPath "$tmpDir/$appName"
|
installAppWithPath "$tmpDir/$appName"
|
||||||
}
|
}
|
||||||
@@ -559,7 +565,7 @@ installFromZIP() {
|
|||||||
# extract info from data
|
# extract info from data
|
||||||
if [ -z "$archiveName" ]; then
|
if [ -z "$archiveName" ]; then
|
||||||
case $type in
|
case $type in
|
||||||
dmg|pkg|zip)
|
dmg|pkg|zip|tbz)
|
||||||
archiveName="${name}.$type"
|
archiveName="${name}.$type"
|
||||||
;;
|
;;
|
||||||
pkgInDmg)
|
pkgInDmg)
|
||||||
@@ -582,7 +588,7 @@ fi
|
|||||||
|
|
||||||
if [ -z "$targetDir" ]; then
|
if [ -z "$targetDir" ]; then
|
||||||
case $type in
|
case $type in
|
||||||
dmg|zip)
|
dmg|zip|tbz)
|
||||||
targetDir="/Applications"
|
targetDir="/Applications"
|
||||||
;;
|
;;
|
||||||
pkg*)
|
pkg*)
|
||||||
@@ -653,7 +659,7 @@ case $type in
|
|||||||
pkg)
|
pkg)
|
||||||
installFromPKG
|
installFromPKG
|
||||||
;;
|
;;
|
||||||
zip)
|
zip|tbz)
|
||||||
installFromZIP
|
installFromZIP
|
||||||
;;
|
;;
|
||||||
*)
|
*)
|
||||||
|
|||||||
@@ -54,9 +54,9 @@ elif [ "$archiveExt" = "dmg" ]; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
hdiutil detach "$dmgmount"
|
hdiutil detach "$dmgmount"
|
||||||
elif [ "$archiveExt" = "zip" ]; then
|
elif [ "$archiveExt" = "zip" ] || [ "$archiveExt" = "tbz" ]; then
|
||||||
# unzip the archive
|
# unzip the archive
|
||||||
unzip -qq "$archiveName"
|
tar -xf "$archiveName"
|
||||||
|
|
||||||
# check if app exists
|
# check if app exists
|
||||||
appPath=$(find "$tmpDir" -name "*.app" -maxdepth 2 -print )
|
appPath=$(find "$tmpDir" -name "*.app" -maxdepth 2 -print )
|
||||||
|
|||||||
Reference in New Issue
Block a user