A ready-to-use CI/CD Pipeline for uploading assets to github releases.
Run the following command:
fluentci run github_pipeline
Use as a Dagger Module:
dagger install github.com/fluent-ci-templates/github-pipeline@main
Call a function from the module:
dagger call release-upload --src . \
--tag v0.1.0 \
--file demo_x86_64-unknown-linux-gnu.tar.gz \
--token GH_TOKEN
Variable | Description |
---|---|
TAG | Tag to upload the file to |
FILE | File to upload |
GH_TOKEN | Github Access Token |
Job | Description |
---|---|
release_upload | Uploads a file to a github release |
releaseUpload(
src: string | Directory,
tag: string,
file: string,
token: string | Secret
): Promise<string>
You can also use this pipeline programmatically:
import { releaseUpload } from "jsr:@fluentci/github";
await releaseUpload(
".",
Deno.env.get("TAG") || "latest",
Deno.env.get("FILE")!,
Deno.env.get("GH_TOKEN")!
);
See fluentci-io/github-release-demo for an example.