diff --git a/docs/about/Version-Control.md b/docs/about/Version-Control.md deleted file mode 100644 index 63a516262..000000000 --- a/docs/about/Version-Control.md +++ /dev/null @@ -1,63 +0,0 @@ -# Version Control - -## Conventional Commits - -A [specification](https://www.conventionalcommits.org/en/v1.0.0) for adding human and machine readable meaning to commit messages. - -**Format**: [optional scope]: - -Example `feat: allow provided config object to extend other configs` -Example `fix: fixed the bug in issue #123` - -**Advantage**: Automated SemVer version management (major.minor.patch), and automated changelogs. - -## Commitizen CLI - -[Commitizen](https://commitizen-tools.github.io/commitizen) is a Python tool to help with creating **conventional commits** and automating version control. - -### Install - -`pip install commitizen` - -### Commiting Code - -- Instead of `git commit` use `cz commit` and follow the prompts. -- You can select the type of commit, plus additional metadata. - -### Bumping a Version - -- When you decide it is time to create a new version: - -1. Create a new branch - -`git checkout -b bump/new_release` - -2. Bump the version and push - -```bash -pip install commitizen # (if not installed) - -cz bump --check-consistency --changelog - -git push -``` - -This will: - -- Update the SemVer version number in locations specific in `pyproject.toml`, throughout the codebase. - - If a `feat` commit is included, the version is bumped by a minor increment (0.x.0), if only `fix` is included a patch will be used (0.0.x). -- Automatically update CHANGELOG.md with all changes since the last version. -- Create a tag matching the version number. - -> Note: in a repo where you have direct push access, you would simply update on main and push. As we are using Git-Flow, a PR is necessary. - -## Creating Releases - -1. Update the version throughout the code ([Bumping a Version](#bumping-a-version)). -2. Go to the [Releases](https://github.com/hotosm/osm_fieldwork/releases) page. -3. Click `Draft a new release`. -4. Click `Choose a tag`, then input the current version number and press enter (this will automatically create a matching tag for your release). -5. Set the `Release title` to v`x.x.x`, replacing with your version number. -6. Add a description if possible, then release. - -This should trigger the PyPi publishing workflow, and your version will be available on [PyPi](https://pypi.org/project/osm_fieldwork/#history). diff --git a/mkdocs.yml b/mkdocs.yml index 8a6162b2e..4178f6c5d 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -69,7 +69,8 @@ nav: - Troubleshooting: about/Troubleshooting.md - Changelog: CHANGELOG.md - Code of Conduct: Code-of-Conduct.md - - License: LICENSE + - License: LICENSE.md + - Versioning: https://docs.hotosm.org/dev-guide/version-control/#creating-releases - User Manual: about/user-manual.md - Core Program Usage: - ODK Client: about/odk_client.md