Skip to content
This repository has been archived by the owner on Sep 22, 2024. It is now read-only.

[ci/cd] better release workflow #97

Open
Tracked by #98
deer opened this issue Feb 8, 2024 · 2 comments
Open
Tracked by #98

[ci/cd] better release workflow #97

deer opened this issue Feb 8, 2024 · 2 comments
Assignees
Labels
priority: medium Do last (delegate?) type: enhancement Improvement to existing feature

Comments

@deer
Copy link
Contributor

deer commented Feb 8, 2024

0.4.28 broke CI due to formatting. But what if it also broke the (currently non-existent) tests?

Ideally there would be a github action that can be triggered via the UI that releases a new version. I'll look into this since I want to learn more about automating projects.

Second followup item from https://github.com/netzo/netzo/pull/95.

@miguelrk
Copy link
Contributor

miguelrk commented Feb 8, 2024

Hmm that would be great. What happened yesterday is that I accidentally made a new 0.4.28 release without having merged my PR. So automating this would help avoid these silly mistakes. The release flow is currently manual, I made it a bit easier with a deno task release X.Y.Z task, so it would be great to have it in CI. Great, feel also free to assign yourself when you want to tackle something 👍🏼

@miguelrk miguelrk added priority: medium Do last (delegate?) type: enhancement Improvement to existing feature labels Feb 8, 2024
@miguelrk miguelrk changed the title Better release workflow [ci/cd] better release workflow Feb 8, 2024
@miguelrk
Copy link
Contributor

miguelrk commented Feb 13, 2024

Notes from discussion with @deer: something like the the following could be brought together into the current tasks/release.ts task or into a single github worfklow under .github/workflows/release.yml:

{
  "tasks": {
    "version:increase": "deno run --allow-read=src/versions.json --allow-write=src/versions.json src/utils/increase_version.ts",
    "version:latest": "deno run --allow-read src/utils/latest_version.ts"
  }
}
// tasks/increase_version.ts:
import { ReleaseType } from "../deps.ts";
import { increaseVersion } from "../version.ts";

increaseVersion(Deno.args[0] as ReleaseType);
// tasks/latest_version.ts:
import { getLatestVersion } from "../version.ts";
console.log(getLatestVersion());

Maybe unjs/magicast, a library to programmatically modify JavaScript and TypeScript source codes with a simplified, elegant and familiar syntax powered by recast and babel, can be useful.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
priority: medium Do last (delegate?) type: enhancement Improvement to existing feature
Projects
None yet
Development

No branches or pull requests

2 participants