setuptools-scm


Namesetuptools-scm JSON
Version 8.1.0 PyPI version JSON
download
home_pageNone
Summarythe blessed package to manage your versions by scm tags
upload_time2024-05-06 15:07:56
maintainerNone
docs_urlNone
authorNone
requires_python>=3.8
licensePermission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
keywords
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # setuptools_scm
[![github ci](https://github.com/pypa/setuptools_scm/workflows/python%20tests+artifacts+release/badge.svg)](https://github.com/pypa/setuptools_scm/actions)
[![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`.


## `pyproject.toml` usage

The preferred way to configure [setuptools-scm] is to author
settings in a `tool.setuptools_scm` section of `pyproject.toml`.

This feature requires setuptools 61 or later.
First, ensure that [setuptools-scm] is present during the project's
build step by specifying it as one of the build requirements.

```toml title="pyproject.toml"
[build-system]
requires = ["setuptools>=64", "setuptools_scm>=8"]
build-backend = "setuptools.build_meta"
```

That will be sufficient to require [setuptools-scm] for projects
that support [PEP 518] like [pip] and [build].

[pip]: https://pypi.org/project/pip
[build]: https://pypi.org/project/build
[PEP 518]: https://peps.python.org/pep-0518/


To enable version inference, you need to set the version
dynamically in the `project` section of `pyproject.toml`:

```toml title="pyproject.toml"
[project]
# version = "0.0.1"  # Remove any existing version parameter.
dynamic = ["version"]

[tool.setuptools_scm]
```

Additionally, a version file can be written by specifying:

```toml title="pyproject.toml"
[tool.setuptools_scm]
version_file = "pkg/_version.py"
```

Where `pkg` is the name of your package.

If you need to confirm which version string is being generated or debug the configuration,
you can install [setuptools-scm] directly in your working environment and run:

```console
$ python -m setuptools_scm
# To explore other options, try:
$ python -m setuptools_scm --help
```

For further configuration see the [documentation].

[setuptools-scm]: https://github.com/pypa/setuptools_scm
[documentation]: https://setuptools-scm.readthedocs.io/


## Interaction with Enterprise Distributions

Some enterprise distributions like RHEL7
ship rather old setuptools versions.

In those cases its typically possible to build by using an sdist against `setuptools_scm<2.0`.
As those old setuptools versions lack sensible types for versions,
modern [setuptools-scm] is unable to support them sensibly.

It's strongly recommended to build a wheel artifact using modern Python and setuptools,
then installing the artifact instead of trying to run against old setuptools versions.


## Code of Conduct


Everyone interacting in the [setuptools-scm] project's codebases, issue
trackers, chat rooms, and mailing lists is expected to follow the
[PSF Code of Conduct].

[PSF Code of Conduct]: https://github.com/pypa/.github/blob/main/CODE_OF_CONDUCT.md


## Security Contact

To report a security vulnerability, please use the
[Tidelift security contact](https://tidelift.com/security).
Tidelift will coordinate the fix and disclosure.

            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "setuptools-scm",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.8",
    "maintainer_email": null,
    "keywords": null,
    "author": null,
    "author_email": "Ronny Pfannschmidt <opensource@ronnypfannschmidt.de>",
    "download_url": "https://files.pythonhosted.org/packages/4f/a4/00a9ac1b555294710d4a68d2ce8dfdf39d72aa4d769a7395d05218d88a42/setuptools_scm-8.1.0.tar.gz",
    "platform": null,
    "description": "# setuptools_scm\n[![github ci](https://github.com/pypa/setuptools_scm/workflows/python%20tests+artifacts+release/badge.svg)](https://github.com/pypa/setuptools_scm/actions)\n[![Documentation Status](https://readthedocs.org/projects/setuptools-scm/badge/?version=latest)](https://setuptools-scm.readthedocs.io/en/latest/?badge=latest)\n[![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)\n\n## about\n\n[setuptools-scm] extracts Python package versions from `git` or\n`hg` metadata instead of declaring them as the version argument\nor in an SCM managed file.\n\nAdditionally, [setuptools-scm] provides setuptools\nwith a list of files that are managed by the SCM <br/>\n(i.e. it automatically adds **all of** the SCM-managed files to the sdist).<br/>\nUnwanted files must be excluded via `MANIFEST.in`.\n\n\n## `pyproject.toml` usage\n\nThe preferred way to configure [setuptools-scm] is to author\nsettings in a `tool.setuptools_scm` section of `pyproject.toml`.\n\nThis feature requires setuptools 61 or later.\nFirst, ensure that [setuptools-scm] is present during the project's\nbuild step by specifying it as one of the build requirements.\n\n```toml title=\"pyproject.toml\"\n[build-system]\nrequires = [\"setuptools>=64\", \"setuptools_scm>=8\"]\nbuild-backend = \"setuptools.build_meta\"\n```\n\nThat will be sufficient to require [setuptools-scm] for projects\nthat support [PEP 518] like [pip] and [build].\n\n[pip]: https://pypi.org/project/pip\n[build]: https://pypi.org/project/build\n[PEP 518]: https://peps.python.org/pep-0518/\n\n\nTo enable version inference, you need to set the version\ndynamically in the `project` section of `pyproject.toml`:\n\n```toml title=\"pyproject.toml\"\n[project]\n# version = \"0.0.1\"  # Remove any existing version parameter.\ndynamic = [\"version\"]\n\n[tool.setuptools_scm]\n```\n\nAdditionally, a version file can be written by specifying:\n\n```toml title=\"pyproject.toml\"\n[tool.setuptools_scm]\nversion_file = \"pkg/_version.py\"\n```\n\nWhere `pkg` is the name of your package.\n\nIf you need to confirm which version string is being generated or debug the configuration,\nyou can install [setuptools-scm] directly in your working environment and run:\n\n```console\n$ python -m setuptools_scm\n# To explore other options, try:\n$ python -m setuptools_scm --help\n```\n\nFor further configuration see the [documentation].\n\n[setuptools-scm]: https://github.com/pypa/setuptools_scm\n[documentation]: https://setuptools-scm.readthedocs.io/\n\n\n## Interaction with Enterprise Distributions\n\nSome enterprise distributions like RHEL7\nship rather old setuptools versions.\n\nIn those cases its typically possible to build by using an sdist against `setuptools_scm<2.0`.\nAs those old setuptools versions lack sensible types for versions,\nmodern [setuptools-scm] is unable to support them sensibly.\n\nIt's strongly recommended to build a wheel artifact using modern Python and setuptools,\nthen installing the artifact instead of trying to run against old setuptools versions.\n\n\n## Code of Conduct\n\n\nEveryone interacting in the [setuptools-scm] project's codebases, issue\ntrackers, chat rooms, and mailing lists is expected to follow the\n[PSF Code of Conduct].\n\n[PSF Code of Conduct]: https://github.com/pypa/.github/blob/main/CODE_OF_CONDUCT.md\n\n\n## Security Contact\n\nTo report a security vulnerability, please use the\n[Tidelift security contact](https://tidelift.com/security).\nTidelift will coordinate the fix and disclosure.\n",
    "bugtrack_url": null,
    "license": "Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:  The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.  THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ",
    "summary": "the blessed package to manage your versions by scm tags",
    "version": "8.1.0",
    "project_urls": {
        "documentation": "https://setuptools-scm.readthedocs.io/",
        "repository": "https://github.com/pypa/setuptools_scm/"
    },
    "split_keywords": [],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "a0b91906bfeb30f2fc13bb39bf7ddb8749784c05faadbd18a21cf141ba37bff2",
                "md5": "12c4718423c2576f507ae5f0385bb098",
                "sha256": "897a3226a6fd4a6eb2f068745e49733261a21f70b1bb28fce0339feb978d9af3"
            },
            "downloads": -1,
            "filename": "setuptools_scm-8.1.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "12c4718423c2576f507ae5f0385bb098",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8",
            "size": 43666,
            "upload_time": "2024-05-06T15:07:55",
            "upload_time_iso_8601": "2024-05-06T15:07:55.071511Z",
            "url": "https://files.pythonhosted.org/packages/a0/b9/1906bfeb30f2fc13bb39bf7ddb8749784c05faadbd18a21cf141ba37bff2/setuptools_scm-8.1.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "4fa400a9ac1b555294710d4a68d2ce8dfdf39d72aa4d769a7395d05218d88a42",
                "md5": "d8046dce093a94dc382b68b45f6a6257",
                "sha256": "42dea1b65771cba93b7a515d65a65d8246e560768a66b9106a592c8e7f26c8a7"
            },
            "downloads": -1,
            "filename": "setuptools_scm-8.1.0.tar.gz",
            "has_sig": false,
            "md5_digest": "d8046dce093a94dc382b68b45f6a6257",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8",
            "size": 76465,
            "upload_time": "2024-05-06T15:07:56",
            "upload_time_iso_8601": "2024-05-06T15:07:56.934002Z",
            "url": "https://files.pythonhosted.org/packages/4f/a4/00a9ac1b555294710d4a68d2ce8dfdf39d72aa4d769a7395d05218d88a42/setuptools_scm-8.1.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-05-06 15:07:56",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "pypa",
    "github_project": "setuptools_scm",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "tox": true,
    "lcname": "setuptools-scm"
}
        
Elapsed time: 1.70170s