Created
September 17, 2015 14:48
-
-
Save slangley/5fa867a990404d4bf696 to your computer and use it in GitHub Desktop.
Wrapper around SBConstants that warns if not installed.
This file contains hidden or 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
#!/bin/bash | |
SWIFT_ARGS= | |
while getopts w opt; do | |
case $opt in | |
w) | |
SWIFT_ARGS='-w' | |
;; | |
esac | |
done | |
shift $((OPTIND-1)) | |
sbconstantsPath=`which sbconstants` | |
echo ${sbconstantsPath} | |
if [[ ! -f ${sbconstantsPath} || -z ${sbconstantsPath} ]]; then | |
echo "WARNING: Skipping Storyboard Constants generation. Install sbconstants to make things easier | |
gem install sbconstants | |
https://github.com/paulsamuels/SBConstants" | |
exit 0; | |
fi | |
sbconstants $SWIFT_ARGS $1 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment