Hack to customize fork awesome
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

44 lines
1.2 KiB

#!/bin/bash
if [ ! -f "./Fork-Awesome/.git" ]; then
echo -e "\x1b[31;1mFA submodule is not initialized, exit...\x1b[m"
echo -e "Hint: try \x1b[36mgit submodule init && git submodule update\x1b[m"
exit
fi
npm install
if [ ! -d "./node_modules" ]; then
echo -e "\x1b[31;1mFnode_modules not found, did npm fail?\x1b[m"
exit
fi
cd Fork-Awesome
echo "=== Ensuring FA is up-to-date ==="
git fetch && git reset --hard origin/master
echo "=== Installing ruby dependencies ==="
echo "This will take a while, but only the first time. Please stand by..."
bundle install --path vendor/bundle
echo
echo "=== Installing NODE dependencies ==="
npm install
echo
echo ">>> If no errors occured, FA should be ready to build."
echo -e "\x1b[90m(npm complaining about vulnerabilities is probably okay)\x1b[m"
cd ..
echo "=== Refreshing templates for building a customized font ==="
rm -rf "./patcher/templates/*"
cp "./Fork-Awesome/src/icons/.fontcustom-manifest.json" "./patcher/templates"
cp "./Fork-Awesome/src/icons/fontcustom.yml" "./patcher/templates"
cp "./Fork-Awesome/src/icons/icons.yml" "./patcher/templates"
cp -R "./Fork-Awesome/src/icons/svg" "./patcher/templates"
(cd ./patcher && node ./patcher-init.js)