{"id":18300447,"url":"https://github.com/comet-ml/git-semver-compute","last_synced_at":"2026-01-21T00:34:20.969Z","repository":{"id":252771135,"uuid":"819962432","full_name":"comet-ml/git-semver-compute","owner":"comet-ml","description":"MIRROR of https://git.sdf.org/CRThaze/git-semver-compute","archived":false,"fork":false,"pushed_at":"2024-06-25T14:26:58.000Z","size":13,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-10-21T18:47:15.093Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":null,"has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/comet-ml.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}},"created_at":"2024-06-25T14:21:30.000Z","updated_at":"2024-08-12T09:52:27.000Z","dependencies_parsed_at":"2024-08-12T15:46:11.760Z","dependency_job_id":null,"html_url":"https://github.com/comet-ml/git-semver-compute","commit_stats":null,"previous_names":["comet-ml/git-semver-compute"],"tags_count":1,"template":false,"template_full_name":"bridgelightcloud/github-mirror-template","purl":"pkg:github/comet-ml/git-semver-compute","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/comet-ml%2Fgit-semver-compute","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/comet-ml%2Fgit-semver-compute/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/comet-ml%2Fgit-semver-compute/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/comet-ml%2Fgit-semver-compute/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/comet-ml","download_url":"https://codeload.github.com/comet-ml/git-semver-compute/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/comet-ml%2Fgit-semver-compute/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28619809,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-20T23:49:58.628Z","status":"ssl_error","status_checked_at":"2026-01-20T23:47:29.996Z","response_time":117,"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-05T15:12:30.724Z","updated_at":"2026-01-21T00:34:20.954Z","avatar_url":"https://github.com/comet-ml.png","language":null,"funding_links":[],"categories":[],"sub_categories":[],"readme":"# Git SemVer Compute\n\nA simple script to use in your projects to calculcate a\n[SemVer](https://semver.org/) compliant verion identifier based on Git Tags\nand Commits.\n\n## Dependencies\n\n- `git`\n- `bash`\n- `perl`\n\n## How it Works\n\nRewinds the commits in the git tree to find one with a tag that is a valid\nSemantic Version. If none is found, the version `0.0.0` is used. If the tag\nis not found on the current commit then metadata will be added to the version\nindicating how many additional commits have been added since the tag along\nwith a short commit hash. Additionally, if there are any uncommited changes in\ntracked files, the diff will be hashed and added to the metadata.\n\nTags which begin with a 'v' will have it removed when evaluating the tag as a\nversion.\n\n## Usage\n\nAdd it to your project as a submodule:\n\n```bash\ngit submodule add https://gitlab.com/CRThaze/git-semver-compute.git .version\n```\n\n### Makefile\n\nEasily make the current version available in your Makefile like so:\n\n```make\n# Use the ?= to allow the version to be overriden easily by passing it in as\n# an environment or build variable.\nVERSION ?= $(shell ./.version/calculate-version.sh)\n\n$(EXECUTABLE):\n  go build -ldflags=\"-X main.Version=$(VERSION)\" -o $(EXECUTABLE) .\n```\n\n### Github Actions\n\n```yaml\non: [push]\njobs:\n  build:\n    steps:\n      - name: Compute SemVer from Tags and Commits\n        id: version\n        run: echo \"VERSION=$(${PWD}/.version/calculate-version.sh)\" \u003e\u003e $GITHUB_OUTPUT\n      - name: Create Archive\n        run: tar -czf mycode-${{ steps.version.outputs.VERSION }}.tar.gz .\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcomet-ml%2Fgit-semver-compute","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcomet-ml%2Fgit-semver-compute","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcomet-ml%2Fgit-semver-compute/lists"}