Install materialize and FA to actually check static build works nicely
Note: It didn't
This commit is contained in:
parent
8ae997e45f
commit
e42e67efdc
5 changed files with 564 additions and 5872 deletions
6398
package-lock.json
generated
6398
package-lock.json
generated
File diff suppressed because it is too large
Load diff
|
@ -3,15 +3,14 @@
|
|||
"version": "1.0.0",
|
||||
"private": true,
|
||||
"description": "Another website, really?",
|
||||
"scripts": {
|
||||
"build": "parcel build --no-source-maps -d static/build static/src/scss/index.scss"
|
||||
},
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "git+https://github.com/RealOrangeOne/website.git"
|
||||
},
|
||||
"homepage": "https://github.com/RealOrangeOne/website#readme",
|
||||
"dependencies": {
|
||||
"parcel-bundler": "1.12.4"
|
||||
"@fortawesome/fontawesome-free": "5.13.0",
|
||||
"materialize-css": "1.0.0",
|
||||
"node-sass": "4.13.1"
|
||||
}
|
||||
}
|
||||
|
|
18
scripts/build-static.sh
Executable file
18
scripts/build-static.sh
Executable file
|
@ -0,0 +1,18 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
export PATH=node_modules/.bin:${PATH}
|
||||
|
||||
set -ex
|
||||
|
||||
rm -rf static/build
|
||||
|
||||
mkdir -p static/build/css static/build/js
|
||||
|
||||
node-sass --include-path node_modules/ -q static/src/scss/index.scss static/build/css/index.css
|
||||
|
||||
# Install materialize CSS
|
||||
cp node_modules/materialize-css/dist/js/materialize.min.js static/build/js/materialize.min.js
|
||||
|
||||
# Install fontawesome
|
||||
cp node_modules/@fortawesome/fontawesome-free/css/all.min.css static/build/css/font-awesome.min.css
|
||||
cp -r node_modules/@fortawesome/fontawesome-free/webfonts static/build/
|
|
@ -15,6 +15,6 @@ fi
|
|||
|
||||
npm ci
|
||||
|
||||
npm run build
|
||||
./scripts/build-static.sh
|
||||
|
||||
./manage.py collectstatic --noinput
|
||||
./manage.py collectstatic --noinput --clear -v 2
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
@import "materialize-css/sass/materialize";
|
Reference in a new issue