This repository has been archived by the owner on Jan 5, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
mv
cmd
to cli
, update workflows, init taskfile
- Loading branch information
Showing
15 changed files
with
76 additions
and
51 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,7 +5,7 @@ | |
*.so | ||
*.dylib | ||
/doko | ||
date.txt | ||
*.txt | ||
|
||
# Test binary, built with `go test -c` | ||
*.test | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,7 +10,7 @@ release: | |
|
||
before: | ||
hooks: | ||
- go mod tidy -compat=1.18 | ||
- go mod tidy | ||
|
||
builds: | ||
- <<: &build_defaults | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
# https://taskfile.dev | ||
|
||
version: "3" | ||
|
||
vars: | ||
DOKO_UNIX_PATH: /usr/local/bin | ||
|
||
tasks: | ||
default: | ||
cmds: | ||
- task: build | ||
|
||
setup: | ||
cmds: | ||
- if [ -f "date.txt" ]; then rm date.txt; fi | ||
- if [ -f "tag.txt" ]; then rm tag.txt; fi | ||
- go run ./scripts/date.go >> date.txt | ||
- git describe --abbrev=0 --tags >> tag.txt | ||
|
||
remove: | ||
cmds: | ||
- sudo rm -rf "{{ .DOKO_UNIX_PATH }}"/doko | ||
|
||
install: | ||
cmds: | ||
- sudo mv doko "{{ .DOKO_UNIX_PATH }}" | ||
|
||
release: | ||
cmds: | ||
- BuildDate="$(cat date.txt)" goreleaser release --rm-dist --timeout 100m | ||
|
||
build: | ||
cmds: | ||
- task: setup | ||
- go mod tidy | ||
- go build -ldflags "-X main.version=$(cat tag.txt) -X main.buildDate=$(cat date.txt)" -o doko | ||
|
||
build-docker: | ||
cmds: | ||
- task: build-docker-cli | ||
|
||
build-docker-cli: | ||
cmds: | ||
- docker build -t dokocli/doko . | ||
- docker push dokocli/doko | ||
|
||
build-docker-full: | ||
dir: ./docker/doko-full | ||
cmds: | ||
- docker build -t dokocli/doko-full . | ||
- docker push dokocli/doko-full |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
package cli | ||
package commands | ||
|
||
import ( | ||
"fmt" | ||
|
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters