Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/dagger-static-checks.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v5
uses: actions/checkout@v6

- name: Run Dagger static checks
uses: dagger/[email protected]
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/dagger-tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v5
uses: actions/checkout@v6

- name: Run Dagger tests and generate report
uses: dagger/[email protected]
Expand Down
31 changes: 14 additions & 17 deletions Taskfile.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
---
version: 3
includes:
git:
taskfile: https://raw.githubusercontent.com/stuttgart-things/platform-engineering-showcase/refs/heads/main/taskfiles/git.yaml

vars:
PROJECT_NAME:
sh: echo ${PWD##*/}
Expand All @@ -11,10 +15,6 @@ vars:
DATE:
sh: date -Ih

includes:
git:
taskfile: https://raw.githubusercontent.com/stuttgart-things/platform-engineering-showcase/refs/heads/main/taskfiles/git.yaml

tasks:
test-all:
cmds:
Expand Down Expand Up @@ -43,11 +43,6 @@ tasks:
FUNCTION: run-static-stage
REPORT_PATH: /tmp/{{ .PROJECT_NAME }}-static-analysis-report.json

default:
desc: Default task is select & do (work)
cmds:
- task do

check:
desc: "Run pre-commit hooks"
cmds:
Expand All @@ -68,12 +63,6 @@ tasks:
- cmd: golangci-lint run
ignore_error: true

test:
desc: Test code
cmds:
- go mod tidy
- cmd: go test ./... -v

tag:
desc: Commit, push & tag the module
deps: [lint, test, commit]
Expand All @@ -83,9 +72,17 @@ tasks:
- git tag -a {{ .TAG }} -m 'updated for stuttgart-things {{.DATE}} for tag version {{ .TAG }}'
- git push origin --tags

default:
desc: Default task is select & do (work)
cmds:
- task do

do:
desc: Select a task to run
cmds:
- |
task=$(yq e '.tasks | keys' Taskfile.yaml | sed 's/^- //' | gum choose)
task ${task}
# Extract task names (keep internal colons, remove only trailing colon)
task_name=$(task -l | awk '/^\*/ {print $2}' | sed 's/:$//' | gum choose)

# Run the selected task
[ -n "$task_name" ] && task "$task_name"
Loading