Skip to content

Commit

Permalink
Merge branch 'main' into patch-1
Browse files Browse the repository at this point in the history
  • Loading branch information
RonnyPfannschmidt authored Jul 28, 2024
2 parents 74fa5be + 0213170 commit 6e81a26
Show file tree
Hide file tree
Showing 4 changed files with 24 additions and 18 deletions.
21 changes: 12 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,19 +1,21 @@
# setuptools_scm
[![github ci](https://github.com/pypa/setuptools_scm/workflows/python%20tests+artifacts+release/badge.svg)](https://github.com/pypa/setuptools_scm/actions)
[![github ci](https://github.com/pypa/setuptools_scm/actions/workflows/python-tests.yml/badge.svg)](https://github.com/pypa/setuptools_scm/actions/workflows/python-tests.yml)
[![Documentation Status](https://readthedocs.org/projects/setuptools-scm/badge/?version=latest)](https://setuptools-scm.readthedocs.io/en/latest/?badge=latest)
[![tidelift](https://tidelift.com/badges/package/pypi/setuptools-scm) ](https://tidelift.com/subscription/pkg/pypi-setuptools-scm?utm_source=pypi-setuptools-scm&utm_medium=readme)

## about

[setuptools-scm] extracts Python package versions from `git` or
`hg` metadata instead of declaring them as the version argument
or in an SCM managed file.

Additionally, [setuptools-scm] provides setuptools
with a list of files that are managed by the SCM <br/>
(i.e. it automatically adds **all of** the SCM-managed files to the sdist).<br/>
Unwanted files must be excluded via `MANIFEST.in`.
[setuptools-scm] extracts Python package versions from `git` or `hg` metadata
instead of declaring them as the version argument
or in a Source Code Managed (SCM) managed file.

Additionally [setuptools-scm] provides `setuptools` with a list of
files that are managed by the SCM
<br/>
(i.e. it automatically adds all the SCM-managed files to the sdist).
<br/>
Unwanted files must be excluded via `MANIFEST.in`
or [configuring Git archive][git-archive-docs].

## `pyproject.toml` usage

Expand Down Expand Up @@ -71,6 +73,7 @@ For further configuration see the [documentation].

[setuptools-scm]: https://github.com/pypa/setuptools_scm
[documentation]: https://setuptools-scm.readthedocs.io/
[git-archive-docs]: https://setuptools-scm.readthedocs.io/en/stable/usage/#builtin-mechanisms-for-obtaining-version-numbers


## Interaction with Enterprise Distributions
Expand Down
15 changes: 9 additions & 6 deletions docs/index.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,16 @@
# About


`setuptools_scm` extracts Python package versions from `git` or `hg` metadata
instead of declaring them as the version argument or in a SCM managed file.
instead of declaring them as the version argument
or in a Source Code Managed (SCM) managed file.

Additionally `setuptools_scm` provides `setuptools` with a list of
files that are managed by the SCM
(i.e. it automatically adds all the SCM-managed files to the sdist).
Unwanted files must be excluded via `MANIFEST.in`
or [configuring Git archive][git-archive-docs].

Additionally `setuptools_scm` provides setuptools with a list of
files that are managed by the SCM (i.e. it automatically adds all
the SCM-managed files to the sdist). Unwanted files must be excluded
via `MANIFEST.in`.
[git-archive-docs]: usage.md#builtin-mechanisms-for-obtaining-version-numbers

## basic usage

Expand Down
2 changes: 1 addition & 1 deletion docs/usage.md
Original file line number Diff line number Diff line change
Expand Up @@ -205,7 +205,7 @@ so you will see an additional `g` prepended to the `{revision hash}`.
be seen in auto-publishing workflows or when a configuration mistake is made.

However, some package indexes such as devpi or other alternatives allow local
versions. Local version identifiers must comply with [PEP 440].
versions. Local version identifiers must comply with [PEP 440](https://peps.python.org/pep-0440/#local-version-identifiers>).

## Semantic Versioning (SemVer)

Expand Down
4 changes: 2 additions & 2 deletions src/setuptools_scm/hg.py
Original file line number Diff line number Diff line change
Expand Up @@ -101,8 +101,8 @@ def get_meta(self, config: Configuration) -> ScmVersion | None:
else:
return meta(tag, config=config, node_date=node_date)

except ValueError as e:
log.exception("error %s", e)
except ValueError:
log.exception("error")
pass # unpacking failed, old hg

return None
Expand Down

0 comments on commit 6e81a26

Please sign in to comment.