mirror of
https://github.com/mtan93/Installomator.git
synced 2026-04-02 06:13:14 +01:00
Update brave.sh
This is a special construction of the `appNewVersion` variable. Not sure this is future proof, but the current one was not working.
This commit is contained in:
@@ -1,15 +1,14 @@
|
|||||||
brave)
|
brave)
|
||||||
# credit: @securitygeneration
|
|
||||||
name="Brave Browser"
|
name="Brave Browser"
|
||||||
type="dmg"
|
type="dmg"
|
||||||
if [[ $(arch) != "i386" ]]; then
|
if [[ $(arch) != "i386" ]]; then
|
||||||
printlog "Architecture: arm64 (not i386)"
|
printlog "Architecture: arm64 (not i386)"
|
||||||
downloadURL=$(curl -fsIL https://laptop-updates.brave.com/latest/osxarm64/release | grep -i "^location" | awk '{print $2}' | tr -d '\r\n')
|
downloadURL=$(curl -fsIL https://laptop-updates.brave.com/latest/osxarm64/release | grep -i "^location" | awk '{print $2}')
|
||||||
else
|
else
|
||||||
printlog "Architecture: i386"
|
printlog "Architecture: i386"
|
||||||
downloadURL=$(curl -fsIL https://laptop-updates.brave.com/latest/osx/release | grep -i "^location" | awk '{print $2}' | tr -d '\r\n')
|
downloadURL=$(curl -fsIL https://laptop-updates.brave.com/latest/osx/release | grep -i "^location" | awk '{print $2}')
|
||||||
fi
|
fi
|
||||||
# downloadURL=$(curl --location --fail --silent "https://updates.bravesoftware.com/sparkle/Brave-Browser/stable/appcast.xml" | xpath '//rss/channel/item[last()]/enclosure/@url' 2>/dev/null | cut -d '"' -f 2)
|
# downloadURL=$(curl -fsL "https://updates.bravesoftware.com/sparkle/Brave-Browser/stable/appcast.xml" | xpath '//rss/channel/item[last()]/enclosure/@url' 2>/dev/null | cut -d '"' -f 2)
|
||||||
appNewVersion=$(curl --location --fail --silent "https://updates.bravesoftware.com/sparkle/Brave-Browser/stable/appcast.xml" | xpath '//rss/channel/item[last()]/enclosure/@sparkle:shortVersionString' 2>/dev/null | cut -d '"' -f 2)
|
appNewVersion="96.$(curl -fsL "https://updates.bravesoftware.com/sparkle/Brave-Browser/stable/appcast.xml" | xpath '//rss/channel/item[last()]/enclosure/@sparkle:shortVersionString' 2>/dev/null | cut -d '"' -f 2 | cut -d "." -f1-3)"
|
||||||
expectedTeamID="KL8N8XSYF4"
|
expectedTeamID="KL8N8XSYF4"
|
||||||
;;
|
;;
|
||||||
|
|||||||
Reference in New Issue
Block a user