Van js slop test
This commit is contained in:
parent
fe9e271a97
commit
633cab2c40
4 changed files with 22 additions and 2 deletions
14
Justfile
14
Justfile
|
|
@ -7,12 +7,17 @@ htmx-sha256sum := "491955cd1810747d7d7b9ccb936400afb760e06d25d53e4572b64b6563b27
|
|||
htmx-file := "htmx.min.js"
|
||||
htmx-url := "https://github.com/bigskysoftware/htmx/releases/download/v" + htmx-ver / htmx-file
|
||||
|
||||
van-ver := "1.5.2"
|
||||
van-sha256sum := "cf0027d9061fb10dc3c7055e0d8e39f3f75a30ab0cf00c3f65933d3f7e3b08e6"
|
||||
van-file := "van.min.js"
|
||||
van-url := "https://vanjs.org/code/" + "van-" + van-ver + ".min.js"
|
||||
|
||||
[doc("Run the server")]
|
||||
run: get-htmx
|
||||
run: get-htmx get-van
|
||||
go run ./http-serve.go
|
||||
|
||||
[doc("Build a static binary with content bundled")]
|
||||
build: get-htmx
|
||||
build: get-htmx get-van
|
||||
go build -o build/htmx-server ./http-serve.go
|
||||
|
||||
# TODO: Maybe use shasum instead for FreeBSD support
|
||||
|
|
@ -21,12 +26,17 @@ get-htmx:
|
|||
@test -f htmx.min.js || echo "Getting HTMX..." && curl --silent -O -lSSL {{htmx-url}}
|
||||
@sha256sum -c <<< "{{htmx-sha256sum}} {{htmx-file}}" || (echo "Checksum failed, check Justfile" && exit 1)
|
||||
|
||||
get-van:
|
||||
@test -f {{van-file}} || echo "Getting Van..." && curl --silent -o {{van-file}} -lSSL {{van-url}}
|
||||
@sha256sum -c <<< "{{van-sha256sum}} {{van-file}}" || (echo "Checksum failed, check Justfile" && exit 1)
|
||||
|
||||
[doc("Cleanup source tree")]
|
||||
[confirm("Are you sure? [y/N]:")]
|
||||
clean: clean-container
|
||||
rm -rf .go
|
||||
rm -rf build
|
||||
rm -f htmx.min.js
|
||||
rm -f van-*.min.js
|
||||
|
||||
# Build the container
|
||||
build-container: get-htmx
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue