2024-12-22 17:01:11 -05:00
|
|
|
version: "3"
|
|
|
|
|
|
|
|
vars:
|
|
|
|
GOPATH:
|
|
|
|
sh: go env GOPATH
|
|
|
|
BIN_DIR: "{{.GOPATH}}/bin"
|
|
|
|
BINARY: "{{.BIN_DIR}}/hway"
|
|
|
|
OS:
|
|
|
|
sh: uname -s
|
|
|
|
ARCH:
|
|
|
|
sh: uname -m
|
|
|
|
|
|
|
|
tasks:
|
|
|
|
build:
|
|
|
|
desc: Build the hway binary
|
|
|
|
silent: true
|
2024-12-22 18:43:30 -05:00
|
|
|
cmds:
|
2024-12-22 21:05:51 -05:00
|
|
|
- templ generate
|
|
|
|
- sqlc generate -f internal/database/sqlc.yaml
|
2024-12-22 17:01:11 -05:00
|
|
|
- gum spin --spinner dot --title "Build Hway Single Target ({{.OS}}/{{.ARCH}})..." -- goreleaser build --snapshot --clean --single-target --id hway -o {{.BIN_DIR}}/hway
|
|
|
|
|
2024-12-22 18:43:30 -05:00
|
|
|
install:
|
|
|
|
desc: Install the hway binary
|
|
|
|
silent: true
|
|
|
|
cmds:
|
2024-12-22 21:05:51 -05:00
|
|
|
- templ generate
|
|
|
|
- sqlc generate -f internal/database/sqlc.yaml
|
2024-12-22 18:43:30 -05:00
|
|
|
- gum spin --spinner dot --title "Install Hway Single Target ({{.OS}}/{{.ARCH}})..." -- make install-hway
|
|
|
|
|
2024-12-22 17:01:11 -05:00
|
|
|
start:
|
|
|
|
desc: Start the hway daemon
|
|
|
|
silent: true
|
|
|
|
cmds:
|
|
|
|
- "{{.BINARY}}"
|