{"id":28719431,"url":"https://github.com/funfair-tech/funfair-build-version","last_synced_at":"2025-06-15T06:02:33.205Z","repository":{"id":39484281,"uuid":"134276698","full_name":"funfair-tech/funfair-build-version","owner":"funfair-tech","description":"Build Versioning tool that works specifically with git and teamcity","archived":false,"fork":false,"pushed_at":"2025-06-11T04:51:35.000Z","size":4716,"stargazers_count":6,"open_issues_count":1,"forks_count":0,"subscribers_count":8,"default_branch":"main","last_synced_at":"2025-06-11T05:35:09.308Z","etag":null,"topics":["dotnet","gitversioning","tool","versioning"],"latest_commit_sha":null,"homepage":"","language":"C#","has_issues":false,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/funfair-tech.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":".github/CODEOWNERS","security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2018-05-21T13:58:12.000Z","updated_at":"2025-06-11T04:45:44.000Z","dependencies_parsed_at":"2023-12-18T22:20:58.158Z","dependency_job_id":"b4dd76db-4f85-4db5-91e4-0e4e06fb66a2","html_url":"https://github.com/funfair-tech/funfair-build-version","commit_stats":{"total_commits":1453,"total_committers":6,"mean_commits":"242.16666666666666","dds":0.00619408121128695,"last_synced_commit":"e2f091c60cc89e1c183bfa7d86f399f9b61d8ca2"},"previous_names":[],"tags_count":1920,"template":false,"template_full_name":null,"purl":"pkg:github/funfair-tech/funfair-build-version","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/funfair-tech%2Ffunfair-build-version","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/funfair-tech%2Ffunfair-build-version/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/funfair-tech%2Ffunfair-build-version/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/funfair-tech%2Ffunfair-build-version/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/funfair-tech","download_url":"https://codeload.github.com/funfair-tech/funfair-build-version/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/funfair-tech%2Ffunfair-build-version/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":259929946,"owners_count":22933527,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":["dotnet","gitversioning","tool","versioning"],"created_at":"2025-06-15T06:01:31.812Z","updated_at":"2025-06-15T06:02:33.168Z","avatar_url":"https://github.com/funfair-tech.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Build Version\n\nSimpler/faster git specific version builder\n\n## Build Status\n\n| Branch  | Status                                                                                                                                                                                                                                                  |\n|---------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| main    | [![Build: Pre-Release](https://github.com/funfair-tech/funfair-build-version/actions/workflows/build-and-publish-pre-release.yml/badge.svg)](https://github.com/funfair-tech/funfair-build-version/actions/workflows/build-and-publish-pre-release.yml) |\n| release | [![Build: Release](https://github.com/funfair-tech/funfair-build-version/actions/workflows/build-and-publish-release.yml/badge.svg)](https://github.com/funfair-tech/funfair-build-version/actions/workflows/build-and-publish-release.yml)             |\n\n## Release Notes/Changelog\n\nView [changelog](CHANGELOG.md)\n\n[CHANGELOG]: ./CHANGELOG.md\n\n## Installation\n\n### Install as a global tool\n```shell\ndotnet tool install FunFair.BuildVersion\n```\n\nTo update to latest released version\n```shell\ndotnet tool update FunFair.BuildVersion\n```\n\n### Install as a local tool\n\n```shell\ndotnet new tool-manifest\ndotnet tool install FunFair.BuildVersion --local\n```\n\nTo update to latest released version\n```shell\ndotnet tool update FunFair.BuildVersion --local\n```\n\n## Supported Branch formats\n\nSupports release and hotfix branches in the following formats\n\n* release/version\n* release/package/version\n* release-platform/package/version\n* release-platform/version\n* hotfix/version\n* hotfix/package/version\n* hotfix-platform/package/version\n* hotfix-platform/version\n\n``version`` can be in the following formats:\n\n* 1\n* 1.2\n* 1.2.3\n\n### Output Release Formats\n\n* Release branches: 1.2.3.4; \n  - where 4 is a build number passed to the tool\n* Pre-Release branches 1.2.3.4-tag\n  - where `4` is a build number passed to the tool\n  - where ``tag`` is generated from the branch name (or matching branch for a pull request if it can be located)\n\nTag restrictions\n\n* Maximum length before truncating after any processing: 15 characters\n* Non alphanumeric characters are replaced with ``-``\n* Multiple ``-`` consecutive characters are shrunk to a single one\n* removes the top folder of the branch when using branches like ``feature/name`` so that tag is processed on ``name`` only\n* For Pull requests, if a branch cannot be located by its SHA hash then the tag will become ``pr-id`` where ``id`` is the id of the pull request\n* if no suitable tag can be generated the tag ``prerelease`` will be used.\n\n### Command line arguments\n\n```\n  -x, --WarningsAsErrors    (Default: false) Whether warnings should be errors\n  -b, --BuildNumber         (Default: -1) The build number (use BUILD_NUMBER envrionment variable)\n  -s, --ReleaseSuffix       (Default: ) The release suffix\n  -p, --Package             (Default: ) The package being released\n  --help                    Display this help screen.\n  --version                 Display version information.\n```\n\n\n\n#### Running without arguments\n\nThis will attempt to retrieve the build number (counter) from an environment variable:\n\n* BUILD_NUMBER   (Set by CI tools like TeamCity)\n\n```shell\ndotnet buildversion\n```\n\n#### Running with release branches in format /release/version\n\n```shell\ndotnet buildversion --BuildNumber 272\n```\n\nor\n\n```shell\ndotnet buildversion --b272\n```\n\n#### Running with release branches in format /release-product/version\n\n```shell\ndotnet buildversion --BuildNumber 272 --ReleaseSuffix \"product\"\n```\n\nor\n\n```shell\ndotnet buildversion -b272  -s\"product\"\n```\n\n#### Running with release branches in format /release-product/package/version\n\n```shell\ndotnet buildversion --BuildNumber 272 --ReleaseSuffix \"product\" --Package \"package\"\n```\n\nor\n\n```shell\ndotnet buildversion -b272  -s\"product\" -p\"package\"\n```\n\n#### Running with release branches in format /release/package/version\n\n```shell\ndotnet buildversion --BuildNumber 272 --Package \"package\"\n```\n\nor\n\n```shell\ndotnet buildversion -b272 -p\"package\"\n```\n\n## Integrations\n\n### TeamCity\n\n* Picks up the ``BUILD_NUMBER`` environment variable for the build number\n* If ``TEAMCITY_VERSION`` environment variable is defined then the ``system.build.version`` and ``buildNumber`` variables will be set to match the build version that the tool produces\n\n### GitHub Actions\n\n* If ``GITHUB_ENV`` environment variable is defined then the ``BUILD_VERSION`` environment variable  will be set to match the build version that the tool produces.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffunfair-tech%2Ffunfair-build-version","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffunfair-tech%2Ffunfair-build-version","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffunfair-tech%2Ffunfair-build-version/lists"}