Skip to content

Commit

Permalink
adjust Justfile
Browse files Browse the repository at this point in the history
  • Loading branch information
alpancs committed Sep 24, 2024
1 parent c419006 commit ef07e0f
Showing 1 changed file with 15 additions and 12 deletions.
27 changes: 15 additions & 12 deletions Justfile
Original file line number Diff line number Diff line change
@@ -1,32 +1,35 @@
vue_version := "3.4.21"
bulma_version := "0.9.4"
fontawesome_version := "6.5.1"
build_dir := "web-app/public"

build-web-app: build-quranize-wasm get-vue get-bulma get-fontawesome
build-web-app: build-wasm get-vue get-bulma get-fontawesome

build-quranize-wasm:
cd web-app && wasm-pack build \
--release \
--target=web \
build-wasm:
wasm-pack build \
--no-typescript \
--out-dir=web-app/scripts/quranize \
--out-name=quranize
--target=web \
--release \
--out-dir=public/scripts/quranize \
--out-name=quranize \
--no-pack \
web-app

get-vue:
wget https://cdn.jsdelivr.net/npm/vue@{{vue_version}}/dist/vue.esm-browser.js -O web-app/web-app/scripts/vue.esm-browser.js
wget https://cdn.jsdelivr.net/npm/vue@{{vue_version}}/dist/vue.esm-browser.js -O {{build_dir}}/scripts/vue.esm-browser.js

get-bulma:
wget https://cdn.jsdelivr.net/npm/bulma@{{bulma_version}}/css/bulma.css -O web-app/web-app/styles/bulma.css
wget https://cdn.jsdelivr.net/npm/bulma@{{bulma_version}}/css/bulma.css -O {{build_dir}}/styles/bulma.css

get-fontawesome:
wget https://use.fontawesome.com/releases/v{{fontawesome_version}}/fontawesome-free-{{fontawesome_version}}-web.zip
unzip fontawesome-free-{{fontawesome_version}}-web.zip
rm -rf fontawesome-free-{{fontawesome_version}}-web.zip web-app/web-app/styles/fontawesome
mv fontawesome-free-{{fontawesome_version}}-web web-app/web-app/styles/fontawesome
rm -rf fontawesome-free-{{fontawesome_version}}-web.zip {{build_dir}}/styles/fontawesome
mv fontawesome-free-{{fontawesome_version}}-web {{build_dir}}/styles/fontawesome

run-server:
static-web-server \
--root=web-app/web-app \
--root={{build_dir}} \
--port=5000 \
--cache-control-headers=false \
--log-level=info

0 comments on commit ef07e0f

Please sign in to comment.