chore: rework release workflows for releasekit#217
Conversation
Greptile SummaryThis PR replaces the bespoke multi-phase release system (four reusable orchestration workflows plus custom TypeScript and shell scripts) with releasekit, consolidating the entire release pipeline into a single reusable workflow and Confidence Score: 5/5Safe to merge — all previously flagged issues are resolved and no new P0/P1 issues found. Every P0 and P1 finding from the prior review round has been addressed in the current implementation. The only open question (potential interaction between setup-node registry-url and releasekit OIDC auth) is speculative and does not constitute a present defect, keeping all remaining concerns at P2 or lower. No files require special attention.
|
| Filename | Overview |
|---|---|
| .github/workflows/_release.reusable.yml | New consolidated reusable release workflow; all previously flagged issues (ssh_key in secrets, Rust-before-build ordering, replace() expression, uses:./) resolved in the current version. |
| .github/workflows/release.yml | Reworked release trigger workflow using releasekit gate mode; GraphQL query removed, label matching delegated to releasekit, scope/target_branch inputs now present for manual runs. |
| .github/workflows/release-preview.yml | Simplified preview workflow; checkout step is now present before the releasekit action. |
| releasekit.config.json | New releasekit configuration; git.branch hardcoding removed, scopeLabels align with documented labels, Ollama baseURL confirmed as cloud API endpoint by author. |
| package.json | Adds @releasekit/release devDependency; no other functional changes. |
| .github/workflows/README.md | Updated to document the new scope/bump/release label system and simplified workflow structure. |
Flowchart
%%{init: {'theme': 'neutral'}}%%
flowchart TD
A[Push to main / workflow_dispatch] --> B{Event type?}
B -- workflow_run CI completed --> C[gate job\nreleasekit mode:gate]
C --> D{should_release?}
D -- false --> E[Skip release]
D -- true --> F[release-auto\ncalls _release.reusable.yml]
B -- workflow_dispatch --> G[release-manual\ncalls _release.reusable.yml]
F --> H[_release.reusable.yml]
G --> H
H --> I[Checkout via SSH]
H --> J[Setup Node / pnpm install]
H --> K{scope contains tauri?}
K -- yes --> L[Setup Rust + GTK]
K -- no --> M[Build packages by scope]
L --> M
M --> N[Configure Git]
N --> O[releasekit mode:release\nversioning + publish + GitHub Release]
PR[Pull Request opened/labeled] --> P[release-preview.yml\nreleasekit mode:preview]
P --> Q[PR comment with version preview]
Reviews (23): Last reviewed commit: "docs: update README to reflect changes i..." | Re-trigger Greptile
…orkflow - Changed error message from "Unknown service" to "Unknown scope" for clarity. - Wrapped target packages in quotes to ensure proper parsing. - Updated release summary to reflect "Scope" instead of "Service". - Added conditional check to display a failure message in the summary if the release step fails.
…puts - Eliminated branch type and feature branch name inputs from the release workflow to streamline the process. - Set the target branch to 'main' directly in the release job, enhancing clarity and reducing complexity in the workflow.
…ssaging - Added `--branch` option to `releasekit` command to ensure it pushes to the correct branch, addressing hardcoded "main" configuration. - Introduced a check for `$HAS_CHANGES` to provide clearer feedback in the release summary, indicating if the release step did not complete successfully.
- Upgraded @releasekit/release, @releasekit/notes, @releasekit/publish, and @releasekit/version to version 0.3.1 in package.json and pnpm-lock.yaml. - Updated smol-toml dependency from 1.6.0 to 1.6.1 for improved functionality.
- Simplified the prerelease bump logic by removing unnecessary conditions for bump types. - Clarified comments regarding the use of prerelease identifiers in the release process.
- Renamed sections in the README to improve understanding of the release process, changing "Release Infrastructure" to "Release Workflow" and "Scopes" to "Version Types". - Consolidated service options under a new "scope" input in the release workflows, allowing for clearer package mapping. - Removed the `release-native.yml` workflow as its functionality is now integrated into the main release workflow, streamlining the release process.
- Upgraded @releasekit/release, @releasekit/notes, @releasekit/publish, and @releasekit/version to version 0.6.1 in package.json and pnpm-lock.yaml. - Updated handlebars dependency from 4.7.8 to 4.7.9 for improved functionality.
- Changed the schema URL in releasekit.config.json to a new location. - Refactored the configuration structure by moving changelog settings under a new "changelog" key and reorganizing release notes settings for clarity. - Updated the release notes configuration to maintain existing functionality while improving organization.
- Modified the release scope description to include 'shared' instead of 'native'. - Updated the workflow filter for the 'shared' scope to reflect the new package mapping.
…d label handling - Introduced a new job to check for release labels on commits, determining if a release should occur based on the presence of specific labels. - Added concurrency control to the release process to manage simultaneous runs. - Updated permissions for actions and contents to align with the new workflow structure. - Refactored the release jobs to separate automatic and manual release processes, improving clarity and organization.
…ocesses - Revised the release process in CONTRIBUTING.md to emphasize automated releases triggered by PR labels. - Enhanced the release workflow description in .github/workflows/README.md to clarify both manual and automated release options. - Updated development.md to align with the new release strategy, detailing the use of labels for automated releases and providing examples for clarity.
- Introduced a new GitHub Actions workflow to generate release previews for pull requests targeting the main branch. - Configured concurrency control to manage simultaneous preview runs and set appropriate permissions for pull requests and content access. - Included steps for checking out the code, setting up Node.js and pnpm, installing dependencies, building packages, and running the release preview command.
- Updated CONTRIBUTING.md to include information about the `release-preview.yml` workflow for PRs with release labels. - Revised .github/workflows/README.md to clarify the role of the `release-preview.yml` in showing potential release outcomes. - Adjusted references in the Docker README to reflect changes in CI workflow documentation.
- Eliminated the build step from the release-preview.yml workflow to streamline the process, focusing on generating release previews directly.
- Updated the release and release preview workflows to utilize ReleaseKit for streamlined release management. - Removed redundant steps and integrated ReleaseKit directly for both release and preview modes, enhancing efficiency and clarity. - Adjusted environment variable handling and output processing to align with the new structure.
- Upgraded ReleaseKit from v0.7.0 to v0.7.11 in both the release and release preview workflows to incorporate the latest features and improvements.
…e.json and workflows
…' prefix and improving error messaging
…i scope in release workflow
…tion in release workflow
…history retrieval
… renaming 'check-labels' to 'gate' and adding Rust and GTK setup steps for Tauri scope
Replacing package-versioner and all the custom release logic with releasekit