{"id":20618950,"url":"https://github.com/jahnf/cmake-gitversion","last_synced_at":"2026-03-19T16:45:12.998Z","repository":{"id":74770652,"uuid":"273446162","full_name":"jahnf/CMake-GitVersion","owner":"jahnf","description":"Automatic version generation for C++ CMake projects.","archived":false,"fork":false,"pushed_at":"2020-06-21T06:55:23.000Z","size":20,"stargazers_count":3,"open_issues_count":1,"forks_count":1,"subscribers_count":1,"default_branch":"develop","last_synced_at":"2025-11-09T13:24:37.835Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"CMake","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jahnf.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2020-06-19T08:40:55.000Z","updated_at":"2025-09-22T08:30:24.000Z","dependencies_parsed_at":"2023-02-26T22:15:48.350Z","dependency_job_id":null,"html_url":"https://github.com/jahnf/CMake-GitVersion","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/jahnf/CMake-GitVersion","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jahnf%2FCMake-GitVersion","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jahnf%2FCMake-GitVersion/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jahnf%2FCMake-GitVersion/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jahnf%2FCMake-GitVersion/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jahnf","download_url":"https://codeload.github.com/jahnf/CMake-GitVersion/tar.gz/refs/heads/develop","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jahnf%2FCMake-GitVersion/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29938962,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-28T13:49:17.081Z","status":"ssl_error","status_checked_at":"2026-02-28T13:48:50.396Z","response_time":90,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-16T12:10:00.342Z","updated_at":"2026-02-28T15:01:06.962Z","avatar_url":"https://github.com/jahnf.png","language":"CMake","funding_links":[],"categories":[],"sub_categories":[],"readme":"# CMake-GitVersion\n\n(Yet another) automatic version generation for C++ CMake projects.\n\n* Generates version information using information from git (tags) with fallback options\n  when building without git (e.g. when building from sources with exported archives).\n* Use custom templates for generated sources (e.g. also create resource files (see examples))\n* Uses semantic versioning (https://semver.org/)\n* Best suited with git-flow workflows\n  * See: https://www.atlassian.com/de/git/tutorials/comparing-workflows/gitflow-workflow\n  * See: https://nvie.com/posts/a-successful-git-branching-model/\n* Generated version strings are compatible to/and can be used by debian and rpm packages.\n\n## Version Generation\n\nDefines\n- `LAST_TAG_VERSION`: latest tagged version (e.g. 1.2.0 for tag v1.2.0) or 0.0.0 if no tag exists.\n- `DIST`: commit count distance to latest version tag.\n\nVersion Number rules:\n- on _master_:  `X.Y.Z`[-`DIST`] (using `LAST_TAG_VERSION`), while `DIST` should always be 0 on the master branch.\n- on _develop_ and other branches: `X.Y.Z`-`ALPHA_FLAG`.`DIST` (using `LAST_TAG_VERSION`, `Y` incremented by 1)\n- on release branches: `X.Y.Z`-`RC_FLAG`.`DIST` (extracting `X.Y.Z` from release branch name or from _develop_ as fallback). \\\n  `DIST` is either calculated to last version tag or to the closest `rc-X.Y.Z` tag.\n- `DIST` is added to all version numbers, except:\n  - Versions on _master_ and on _hotfix_ branches with `DIST` equal to 0\n- All version numbers have a pre-release identifier set, except:\n  - Version on _master_ and\n  - versions on _hotfix_ branches with `DIST` equal to 0\n- When creating the version string and the PATCH number is 0 - the patch number is omitted.\n  (e.g. 1.2.0 will be 1.2)\n\n\n## Examples\n\nHave a look at [CMakeLists.txt](./CMakeLists.txt) and all fles in the `examples` directory.\n\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjahnf%2Fcmake-gitversion","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjahnf%2Fcmake-gitversion","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjahnf%2Fcmake-gitversion/lists"}