|
| 1 | +# Release Process for tsgrok |
| 2 | + |
| 3 | +This document outlines the steps to create a new release for the `tsgrok` project using GoReleaser. |
| 4 | + |
| 5 | +## Prerequisites |
| 6 | + |
| 7 | +1. Ensure `goreleaser` is installed and configured correctly. |
| 8 | +2. Ensure you have rights to push to the repository and create releases on GitHub. |
| 9 | +3. Make sure your GPG key is configured for signing. |
| 10 | + |
| 11 | +## Steps to Create a Release |
| 12 | + |
| 13 | + |
| 14 | +1. **Determine the New Version:** |
| 15 | + * Decide on the new version number (e.g., `v0.1.0`, `v1.2.3`). |
| 16 | + |
| 17 | +2. **Create an Annotated Git Tag:** |
| 18 | + * Create an annotated and GPG-signed tag for the new version. Replace `vX.Y.Z` with your chosen version number and provide a meaningful tag message. |
| 19 | + ```bash |
| 20 | + git tag -a vX.Y.Z -m "Release version vX.Y.Z" |
| 21 | + ``` |
| 22 | +3. **Push Changes and Tag to GitHub:** |
| 23 | + * Push your commits and the new tag to the remote repository: |
| 24 | + ```bash |
| 25 | + git push origin main # Or your primary branch |
| 26 | + git push origin vX.Y.Z |
| 27 | + ``` |
| 28 | + (Replace `vX.Y.Z` with your actual tag) |
| 29 | + Alternatively, to push all tags: |
| 30 | + ```bash |
| 31 | + git push --tags |
| 32 | + ``` |
| 33 | + |
| 34 | +4. **Run GoReleaser:** |
| 35 | + * Execute the `goreleaser release` command. This will build the project, create the release on GitHub, and upload the artifacts. |
| 36 | + ```bash |
| 37 | + goreleaser release --clean |
| 38 | + ``` |
| 39 | + * The `--clean` flag ensures that the `dist` directory is cleaned before building, which is good practice. |
| 40 | + * If you have a CI/CD pipeline set up, this step might be triggered automatically when a new tag is pushed. |
| 41 | + |
| 42 | +5. **Verify Release:** |
| 43 | + * Go to the releases page on GitHub for the project and verify that the new release is present with all artifacts and release notes (if `goreleaser` is configured to generate them from your changelog). |
0 commit comments