https://github.com/ushiradineth/semver_ci
Automate Semantic Versioning a Git Flow Repository
https://github.com/ushiradineth/semver_ci
bash contributions-welcome first-contributions
Last synced: 4 months ago
JSON representation
Automate Semantic Versioning a Git Flow Repository
- Host: GitHub
- URL: https://github.com/ushiradineth/semver_ci
- Owner: ushiradineth
- Created: 2024-02-02T14:25:29.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2024-02-03T07:19:26.000Z (over 1 year ago)
- Last Synced: 2025-03-15T11:50:05.263Z (7 months ago)
- Topics: bash, contributions-welcome, first-contributions
- Language: Shell
- Homepage:
- Size: 9.77 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# SemVerCI
Automate Semantic Versioning a Git Repository using [GitFlow](https://nvie.com/posts/a-successful-git-branching-model/) Standards
## Disclaimer
- Please note that GitHub workflows provided in this repository are not tested extensively. Use them at your own risk.
- The scripts are not dependant on Bitbucket Pipelines but was only tested on it.## Contributing
- Contributions via pull requests are appreciated. Feel free to suggest improvements or report issues.
## Usage
### To switch from Node.js versioning to Spring Boot versioning, make the following changes
- Comment out or remove the Node.js versioning related commands in the version.sh script.
- Uncomment or add Spring Boot versioning related commands in the version.sh script.## Versioning Scripts
- ‘version.sh’
The ‘version.sh’ script that is used for maintaining the semantic versioning system. It takes two arguments:1. Release (snapshot, rc, main):
- snapshot: Sets the version to ‘2.0.0-SNAPSHOT’ in the ‘develop’ branch.
- rc: Increments and sets the release candidate version in release branches (2.0.0-rc1, 2.0.0-rc2, etc.).
- main: Cleans up build tags in the main branch (2.0.0-rc1 to 2.0.0) and creates a Git Tag with the version.
2. Semantic Version (major, minor, patch): Increments the specified segment of the semantic version.
- ‘release.sh’
The ‘release.sh’ script is part of the main pipeline. It compares release and develop versions and updates the develop version if needed.- ‘hotfix.sh’
The ‘hotfix.sh’ script is part of the main pipeline. It increments the patch version for hotfixes, updates develop if needed, and commits the changes.- ‘initiate-release-branch.sh’
The ‘initiate-release-branch.sh’ script creates a release branch from the develop branch.