Created
April 1, 2023 04:11
-
-
Save BlazerYoo/379dfe6696748b4716e1cb058219eb81 to your computer and use it in GitHub Desktop.
Use bash script to set up node-sass for Bulma (adapted from https://bulma.io/documentation/customize/with-node-sass/)
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
echo 'MAKING BULMA DIRECTORY...' | |
mkdir bulma-sass | |
cd bulma-sass | |
echo $'\nSpecify entry point: sass/styles.scss' | |
echo $'\nINITIALIZING NPM PROJECT...' | |
npm init | |
echo $'\nINSTALLING DEPENDENCIES...' | |
npm install node-sass --save-dev | |
npm install bulma --save-dev | |
echo $'\nMAKING SASS DIRECTORY + FILE...' | |
mkdir sass | |
cd sass | |
echo $'@charset "utf-8";\n@import "../node_modules/bulma/bulma.sass";' > styles.scss | |
echo $'\nADDING CSS BUILD COMMANDS...' | |
cd .. | |
npm set-script css-build "node-sass --omit-source-map-url sass/styles.scss css/styles.css" | |
npm set-script "css-watch" "npm run css-build -- --watch" | |
npm set-script "start" "npm run css-watch" | |
echo $'\nTO BUILD CSS RUN, npm run css-build\n' | |
read -n 1 -p 'Press [ENTER] to terminate' mainmenuinput | |
exit 0 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment