aboutsummaryrefslogtreecommitdiff
path: root/justfile
diff options
context:
space:
mode:
authorDaniel Schadt <kingdread@gmx.de>2023-03-22 20:34:48 +0100
committerDaniel Schadt <kingdread@gmx.de>2023-03-22 20:47:53 +0100
commite694aaf332b3e6e7d86220936773c7818c5bd5aa (patch)
treea91d47aa37e0aba1b8e51696833b6f1bb4372802 /justfile
parent4c2856bbc6f33c6e1d175702eec2fbb4af6f7deb (diff)
downloadfietsboek-e694aaf332b3e6e7d86220936773c7818c5bd5aa.tar.gz
fietsboek-e694aaf332b3e6e7d86220936773c7818c5bd5aa.tar.bz2
fietsboek-e694aaf332b3e6e7d86220936773c7818c5bd5aa.zip
use npm to manage Javascript libraries
I'm not the biggest fan of combining many package managers, but the JavaScript libraries (Bootstrap, Bootstrap-Icons, later the @types modules and Leaflet) are easy to get via npm, so maybe we can use that to our advantage and have npm at least download them.
Diffstat (limited to 'justfile')
-rw-r--r--justfile10
1 files changed, 10 insertions, 0 deletions
diff --git a/justfile b/justfile
index fc29e00..74af962 100644
--- a/justfile
+++ b/justfile
@@ -58,3 +58,13 @@ compile-language locale:
# Extract new messages from the source files
extract-messages:
pybabel extract -F babel.cfg -o fietsboek/locale/fietslog.pot --input-dirs=fietsboek
+
+# Copy the assets from the NPM packages
+copy-npm-assets:
+ # Bootstrap
+ cp node_modules/bootstrap/dist/js/bootstrap.bundle.min.js fietsboek/static/bootstrap.bundle.min.js
+ cp node_modules/bootstrap/dist/css/bootstrap.css fietsboek/static/bootstrap.css
+ # Bootstrap icons
+ cp node_modules/bootstrap-icons/font/bootstrap-icons.css fietsboek/static/bootstrap-icons.css
+ cp node_modules/bootstrap-icons/font/fonts/bootstrap-icons.woff fietsboek/static/fonts/bootstrap-icons.woff
+ cp node_modules/bootstrap-icons/font/fonts/bootstrap-icons.woff2 fietsboek/static/fonts/bootstrap-icons.woff2