Created
January 8, 2018 07:38
-
-
Save alswl/c52e4b448f8e37c125882558b19620fb to your computer and use it in GitHub Desktop.
brew cask cctalk
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
XML_URL=`c Casks/cctalk.rb G appcast | awk -F "'" '{print $2}'` | |
XML_SHA256=`curl -s $XML_URL | gsha256sum` | |
PUBDATE=`curl -s $XML_URL | xmlstarlet sel -t -v '//pubDate' | awk '{print $1}'` | |
VERSION=`curl -s $XML_URL | xmlstarlet sel -t -v '//title' | awk '{print $2}'` | |
BUILD=`curl -s $XML_URL | xmlstarlet sel -t -v '//sparkle:version'` | |
VERSION_ALL="$VERSION-$BUILD,$PUBDATE" | |
sed -i "s/version .*/version '$VERSION_ALL'/" Casks/cctalk.rb | |
sed -i "s/sha256 .*/sha256 ''/" Casks/cctalk.rb |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment