diff --git a/.gitea/workflows/ci.yml b/.gitea/workflows/ci.yml index 1f2c092..077f6c4 100644 --- a/.gitea/workflows/ci.yml +++ b/.gitea/workflows/ci.yml @@ -33,11 +33,11 @@ jobs: run: go test -v ./... - name: Build - run: go build -o ./bin/triplex-example ./cmd/triplex-example + run: go build -o ./bin/triplex ./cmd/triplex - name: Run example run: | - if ./bin/triplex-example && ./bin/triplex-example --complete ABC-123-DE; then + if ./bin/triplex && ./bin/triplex --complete ABC-123-DE; then echo "Example ran successfully" else echo "Example failed" diff --git a/Makefile b/Makefile index 238a798..5ab5daa 100644 --- a/Makefile +++ b/Makefile @@ -1,16 +1,16 @@ # Copyright (c) 2026 Micha Hoiting -APP_EXAMPLE := triplex-example +APP_EXAMPLE := triplex -.PHONY: test build-example run-example fmt +.PHONY: test build-triplex run-triplex fmt test: go test ./... -build-example: +build-triplex: go build -o bin/$(APP_EXAMPLE) ./cmd/$(APP_EXAMPLE) -run-example: +run-triplex: go run ./cmd/$(APP_EXAMPLE) fmt: diff --git a/cmd/triplex-example/main.go b/cmd/triplex/main.go similarity index 97% rename from cmd/triplex-example/main.go rename to cmd/triplex/main.go index 8e338d6..4497dee 100644 --- a/cmd/triplex-example/main.go +++ b/cmd/triplex/main.go @@ -31,7 +31,7 @@ func myRandomIndex(max uint) (uint, error) { } func main() { - complete := flag.String("complete", "", "complete code without checksum in format LLL-NNN-L") + complete := flag.String("complete", "", "complete code without checksum in format LLL-NNN-LL") flag.Parse() if *complete != "" {