diff options
Diffstat (limited to 'internal/workflows/release.go')
| -rw-r--r-- | internal/workflows/release.go | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/internal/workflows/release.go b/internal/workflows/release.go new file mode 100644 index 00000000..8b7f30bb --- /dev/null +++ b/internal/workflows/release.go @@ -0,0 +1,37 @@ +//go:build workflows + +package main + +var _ = (&Workflow{ + Name: "Release", + On: Map[any]{{K: "push", V: Map[string]{{K: "tags", V: "v*"}}}}, + + Jobs: []KV[Job]{ + {K: "release", V: Job{ + Name: "Create release", + On: "nix", + + Steps: []Step{ + {Name: "Checkout", Uses: "actions/checkout@v4"}, + + { + Name: "Build for release", + Run: "nix build " + + "--print-out-paths " + + "--print-build-logs " + + "./test#dist", + }, + + { + Name: "Release", + Uses: "https://gitea.com/actions/release-action@main", + + With: []KV[any]{ + {K: "files", V: "result/hakurei-**"}, + {K: "api_key", V: "${{secrets.RELEASE_TOKEN}}"}, + }, + }, + }, + }}, + }, +}).mustWriteFile("release") |
