This Gradle plugin derives your project’s version directly from the state of the Git repository, turning tags and commits into consistent semantic versions. It reads the most recent tag, the number of commits since that tag, and whether the working tree is dirty, then composes a deterministic version string. Teams can enforce patterns (for example, treating non-tagged builds as snapshots) and keep CI builds reproducible without hardcoding versions in build.gradle. The plugin integrates with Gradle’s project.version, so the computed version flows automatically into publishing, packaging, and artifact naming. It works well in branching workflows by incorporating branch or distance information, making debug artifacts easy to trace back to source. By centralizing version logic around Git history, it eliminates manual bumps and reduces mistakes when cutting releases across multiple modules.

Features

  • Generates version strings based on Git tags and commit history
  • Mimics git describe --tags --always --first-parent behavior
  • Appends .dirty when repository contains uncommitted changes
  • Automatically injects version logic into the Gradle project
  • Useful for reproducible builds and CI version tracking
  • Actively maintained with latest release version 4.0.0 (June 27, 2025)

Project Samples

Project Activity

See All Activity >

Categories

Git

License

Apache License V2.0

Follow Gradle Git Version

Gradle Git Version Web Site

Other Useful Business Software
MongoDB Atlas runs apps anywhere Icon
MongoDB Atlas runs apps anywhere

Deploy in 115+ regions with the modern database for every enterprise.

MongoDB Atlas gives you the freedom to build and run modern applications anywhere—across AWS, Azure, and Google Cloud. With global availability in over 115 regions, Atlas lets you deploy close to your users, meet compliance needs, and scale with confidence across any geography.
Start Free
Rate This Project
Login To Rate This Project

User Reviews

Be the first to post a review of Gradle Git Version!

Additional Project Details

Programming Language

Groovy

Related Categories

Groovy Git Software

Registered

2025-09-03