Rename cmd/triplex-example to cmd/triplex
All checks were successful
CI / test (push) Successful in 16s
All checks were successful
CI / test (push) Successful in 16s
This commit is contained in:
@@ -33,11 +33,11 @@ jobs:
|
|||||||
run: go test -v ./...
|
run: go test -v ./...
|
||||||
|
|
||||||
- name: Build
|
- name: Build
|
||||||
run: go build -o ./bin/triplex-example ./cmd/triplex-example
|
run: go build -o ./bin/triplex ./cmd/triplex
|
||||||
|
|
||||||
- name: Run example
|
- name: Run example
|
||||||
run: |
|
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"
|
echo "Example ran successfully"
|
||||||
else
|
else
|
||||||
echo "Example failed"
|
echo "Example failed"
|
||||||
|
|||||||
8
Makefile
8
Makefile
@@ -1,16 +1,16 @@
|
|||||||
# Copyright (c) 2026 Micha Hoiting
|
# 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:
|
test:
|
||||||
go test ./...
|
go test ./...
|
||||||
|
|
||||||
build-example:
|
build-triplex:
|
||||||
go build -o bin/$(APP_EXAMPLE) ./cmd/$(APP_EXAMPLE)
|
go build -o bin/$(APP_EXAMPLE) ./cmd/$(APP_EXAMPLE)
|
||||||
|
|
||||||
run-example:
|
run-triplex:
|
||||||
go run ./cmd/$(APP_EXAMPLE)
|
go run ./cmd/$(APP_EXAMPLE)
|
||||||
|
|
||||||
fmt:
|
fmt:
|
||||||
|
|||||||
@@ -31,7 +31,7 @@ func myRandomIndex(max uint) (uint, error) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func main() {
|
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()
|
flag.Parse()
|
||||||
|
|
||||||
if *complete != "" {
|
if *complete != "" {
|
||||||
Reference in New Issue
Block a user