Contents Menu Expand Light mode Dark mode Auto light/dark, in light mode Auto light/dark, in dark mode Skip to content
setuptools-git-versioning 3.1.0
setuptools-git-versioning 3.1.0
  • Comparison with other tools

How to

  • Install
  • Console command
  • CI configuration
  • Retrieving package version at runtime
  • Supporting git archive builds
  • Versioning schemas
    • Tag-based release (not recommended)
      • Release is a git tag
      • Post release
      • Dirty version
    • File-based release (recommended)
      • Read some file content as current version
      • Development releases (prereleases) from dev branch
      • Development releases from any branch
      • Development releases using only branch name
    • Callback-based release (advanced)
      • Execute some callback function to get current version
  • Config options
    • enabled
    • starting_version
    • template
    • dev_template
    • dirty_template
    • version_file
    • count_commits_from_version_file
    • version_callback
    • sort_by
    • branch_formatter
    • tag_formatter
    • tag_filter
  • Template substitutions
    • tag
    • ccount
    • sha
    • full_sha
    • branch
    • env
    • timestamp
  • Common issues
    • Every version built by CI is dirty
    • Wrong tag ordering/latest tag number detection
    • Sphinx usage

Develop

  • Changelog
    • 3.1.x
    • 3.0.x
    • 2.1.x
    • 2.0.x
    • 1.13.x
    • 1.12.x
    • 1.11.x
    • 1.10.x
    • 1.9.x
    • 1.8.x
    • 1.7.x
    • 1.6.x
    • 1.5.x
    • 1.4.x
    • 1.3.x
    • 1.2.x
    • 1.1.x
  • Contributing Guide

Project Links

  • Source Code
  • CI/CD
  • Issue Tracker
Back to top
View this page

ccount¶

Substituted by current number of commits since tag (in case of using Release is a git tag) or since last commit to a version file (in case of using Read some file content as current version with count_commits_from_version_file option).

If commit counts cannot be determined, 0 value is used (since v3.0.0).

Example¶

"{ccount}"

Options¶

No

Next
sha
Previous
tag
Copyright © 2020-present, dolfinus
Made with Sphinx and @pradyunsg's Furo
Last updated on Jan 16, 2026
On this page
  • ccount
    • Example
    • Options