jaraco/jaraco.vcs


License: MIT

Language: Python


tests Ruff https://img.shields.io/badge/skeleton-2024-informational

Usage

jaraco.vcs provides classes for inspecting and working with repositories in the Mercurial and Git version control systems (VCS).

The classes provided are designed to use subprocess invocation to leverage the command-line interfaces of the VCS tools hg and git. An in-process Repo for Mercurial exists but has been disabled due to issues that arise when run in certain environments (namely setuptools sandboxing).

Auto Version Numbering

This project adds support for automatically generating project version numbers from a source code repository under development.

To use this feature, the project must follow the following assumptions:

  • Repo tags are used to indicate released versions.
  • Tag names are specified as the version only (i.e. 0.1 or v0.1 and not release-0.1)
  • Released versions currently must conform to the Version in packaging. Any tags that don't match this scheme will be ignored.

Thereafter, use the Repo.get_current_version to determine the version of the local code. If the current revision is tagged with a valid version, that version will be used. Otherwise, the tags in the repo will be searched, the latest release will be found, and the function will infer the upcoming release version.

For example, if the repo contains the tags 0.1, 0.2, and 0.3 and the repo is not on any of those tags, get_current_version will return '0.3.1dev' and get_current_version(increment='0.1') will return '0.4dev'.

Example:

>>> import jaraco.vcs
>>> jaraco.vcs.repo().get_current_version()
'9.0.1.dev0'

Project Statistics

Sourcerank 8
Repository Size 1.16 MB
Stars 1
Forks 2
Watchers 4
Open issues 2
Dependencies 39
Contributors 25
Tags 114
Created
Last updated
Last pushed

Top Contributors See all

Jason R. Coombs Jannis Leidel Sviatoslav Sydorenko (Святослав Сидоренко) Hugo van Kemenade Anderson Bravalheri Dimitri Papadopoulos Orfanos Bartosz Sławecki Wim Jeantine-Glenn Berry Phillips KOLANICH Christian Clauss Brian Rutledge Alan Fregtman Zach Burnett Joyce Vincent Fazio Avasam Marc Abramowitz johnthagen layday

Packages Referencing this Repo

hgtools
Classes for Mercurial and Git repositories
Latest release 10.1.0 - Updated - 1 stars
jaraco.vcs
Facilities for working with VCS repositories
Latest release 2.4.0 - Updated - 1 stars

Recent Tags See all

v2.4.0 August 06, 2024
v2.3.1 August 01, 2024
v2.3.0 July 28, 2024
v2.2.0 April 24, 2024
v2.1.0 April 22, 2024
v2.0.0 December 05, 2023
v1.3.0 December 05, 2023
v1.2.0 December 05, 2023
v1.1.0 June 21, 2023
v1.0.0 June 20, 2023
hgtools-v10.1.0 June 20, 2023
hgtools-v10.0.0 June 20, 2023
hgtools-v9.2.0 June 20, 2023
hgtools-v9.1.0 January 10, 2022
hgtools-v9.0.0 October 03, 2021

Something wrong with this page? Make a suggestion

Last synced: 2024-08-06 19:24:02 UTC

Login to resync this repository