dnote/scripts/cli/dev.sh
Sung ca5af5e34a
Run server on port 3001 (#687)
* Simplify docker compose file

* Run on port 3001
2025-10-11 12:41:51 -07:00

11 lines
383 B
Bash
Executable file

#!/usr/bin/env bash
# dev.sh builds a new binary and replaces the old one in the PATH with it
set -eux
dir=$(dirname "${BASH_SOURCE[0]}")
sudo rm -rf "$(which dnote)" "$GOPATH/bin/cli"
# change tags to darwin if on macos
go install -ldflags "-X main.apiEndpoint=http://127.0.0.1:3001/api" --tags "linux fts5" "$dir/../../pkg/cli"
sudo ln -s "$GOPATH/bin/cli" /usr/local/bin/dnote