CoCalc is a real-time collaborative commercial alternative to JupyterHub and Overleaf that provides Jupyter Notebooks, LaTeX documents, and SageMath.
CoCalc is a real-time collaborative commercial alternative to JupyterHub and Overleaf that provides Jupyter Notebooks, LaTeX documents, and SageMath.
Path: blob/master/PHEx/build.sh
Views: 713
# PHEx Build Script12# Prefix3PREFIX="[PHEx Builder] "45echo ""67# echo with prefix8xlog () {9echo "$PREFIX$1"10}1112# exit with message13ext () {14echo "$1"15exit 016}1718192021# Delete build/extension.zip22xlog "Deleting extension.zip..."23rm build/extension.zip && xlog "Deleted extension.zip" || xlog "No extension.zip found"242526# Delete build/extension.xpi27xlog "Deleting extension.xpi..."28rm build/extension.xpi && xlog "Deleted extension.xpi" || xlog "No extension.xpi found"29echo ""3031323334# Tell the user that the chromium extension is being zipped35xlog "Zipping chromium extension..."3637# Go into ./src/38cd ./src/3940# Zip ./src/ to ./build.extension.zip41zip -q -r ../build/extension.zip ./ && xlog ".ZIP chromium extension built -> extension.zip"4243# Tell the user that we've build the chromium extension successfully.44xlog "Chromium extension Success!" && echo ""45464748495051# Go out of ./src/ and into ./firefox/52cd ../firefox/5354# Zip ./firefox/ to ./build.extension.xpi55zip -q -r ../build/extension.xpi ./ && xlog ".XPI file built -> extension.xpi"565758# Tell the user that we've build the firefox extension successfully.59xlog "Firefox extension Success!" && echo ""6061626364# When making .crx extensions, it needs to be signed with a private key file to work.65# Tell the user that extension.crx needs to be signed if it's a production-used release.66echo "\033[0;31m" && xlog "IMPORTANT: IF YOU ARE MAKING AN OFFICIAL PHEx RELEASE, THEN PLEASE REMEMBER TO SIGN THE .CRX WITH A PRIVATE KEY FILE." && echo ""6768# Tell the user that we're done.69echo "\033[0m" && xlog "Done!"7071