From nobody Tue Mar 21 19:27:24 2023 X-Original-To: dev-commits-ports-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4Ph1p73z5Vz40hSF; Tue, 21 Mar 2023 19:27:27 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Ph1p65NzGz4MFM; Tue, 21 Mar 2023 19:27:26 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1679426846; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=yQefc42nf7eP1mSJVSQfhLvrS6ytJQfw6qzf9xjoGZk=; b=ZKfE2zyDB7325w98lEZEpniLG+34bM4jxWUmQq5YX7IKPSAwssNRVcrXZtH6g3R2A1bnEk 6KigAe7voFmPSkOHzBeEgV9hI8wySriyhv0sZjYW/qZFGTO0zO7BzNeJChvT+z+d6X2ye8 CcevQs/yozA4la2daROb5KfiSad4lSOBDITmX9FJtp9AR4m+nw2/v94Z+0wtX90PjVp+GE +oDBOaleItpYir61JA4/gQFU4pDeRWDVURaVpUkTbt8sK0b+M3VW1d5+GpeKPp7A70h7Ty OxO1UoIKbcph2Cxx0TVdg38HiChJRfC9vn8WNUmWebc5gxRPycrwj00YDclhjw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1679426846; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=yQefc42nf7eP1mSJVSQfhLvrS6ytJQfw6qzf9xjoGZk=; b=mq5jN2VRbT5qUazqpSRikt4byJL7L81YOThTMfmjjcpCA30B2ogx1H0dW8ioJO/z4z7TJR fVNthCh3/qkVwzQcveyggU3rg4J++2Grc1Du0GXRH7/g+469wVP68RXOpS4CgBWvC+AZd8 HsgZvV/+mua2UNfYyGZPaGW3aHdPHsNafetY+5dyFJkoiCprhMXXun9C6phMpRFVomwuSZ X5bmMG2gA3VKYejbvrOOZHB6C7Xg92zvqy4J2OStC9lYsZPvr+jawo6Uk/JO1cqgIkym9P b2z5gba+UN9EoyLh6A4U4Ytuf+/Op1QpbgHUSdqgENS5BCy0yyWtBGpwuc3TCw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1679426846; a=rsa-sha256; cv=none; b=rwLGwL7sUzbQvMePP4uRvIefl9dnQ0IKScDfaez9AGQXEuC54BTKmehv9pILPoi6R2oXIr W55ryvFut1eqtNmlYwxO31IWfEyZc1ZjyGu/2c+lfvGI94No7FUuLh/S+goGYSLMt20r36 JLYFf4xxirYzwA35v8U2ISvmRbLP6ZY05BxOWAyS3z9sVXm74EqGHWh1PmkyOIDJQwpbQ9 X5rhkpFK3k1TV5qSryUnRf6ypXPFLFK8SRK+bhGGkFr0C0cqeYiLEkM7TOQi8XpmZnDuUH lMKUf4zUxgLEt0VdWSPou97Yvr3wsXdQTdhKByQgwXhBsae/et/Ypt9O5gFGyw== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4Ph1p447dpzPkK; Tue, 21 Mar 2023 19:27:24 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 32LJROZc030917; Tue, 21 Mar 2023 19:27:24 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 32LJRO7j030916; Tue, 21 Mar 2023 19:27:24 GMT (envelope-from git) Date: Tue, 21 Mar 2023 19:27:24 GMT Message-Id: <202303211927.32LJRO7j030916@gitrepo.freebsd.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org From: Po-Chuan Hsieh Subject: git: 3911e01f5b28 - main - devel/py-hatch-vcs: Convert to USE_PYTHON=pep517 List-Id: Commit messages for all branches of the ports repository List-Archive: https://lists.freebsd.org/archives/dev-commits-ports-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-ports-all@freebsd.org X-BeenThere: dev-commits-ports-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: sunpoet X-Git-Repository: ports X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 3911e01f5b28619bf23e61f1a7c4ab0af8260849 Auto-Submitted: auto-generated X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by sunpoet: URL: https://cgit.FreeBSD.org/ports/commit/?id=3911e01f5b28619bf23e61f1a7c4ab0af8260849 commit 3911e01f5b28619bf23e61f1a7c4ab0af8260849 Author: Po-Chuan Hsieh AuthorDate: 2023-03-21 18:44:02 +0000 Commit: Po-Chuan Hsieh CommitDate: 2023-03-21 19:20:40 +0000 devel/py-hatch-vcs: Convert to USE_PYTHON=pep517 - Bump PORTREVISION for dependency and package change --- devel/py-hatch-vcs/Makefile | 8 +++----- devel/py-hatch-vcs/files/setup.py | 33 --------------------------------- 2 files changed, 3 insertions(+), 38 deletions(-) diff --git a/devel/py-hatch-vcs/Makefile b/devel/py-hatch-vcs/Makefile index 90d49b21dc32..899a7b35f6cb 100644 --- a/devel/py-hatch-vcs/Makefile +++ b/devel/py-hatch-vcs/Makefile @@ -1,5 +1,6 @@ PORTNAME= hatch-vcs PORTVERSION= 0.3.0 +PORTREVISION= 1 CATEGORIES= devel python MASTER_SITES= PYPI PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX} @@ -12,18 +13,15 @@ WWW= https://github.com/ofek/hatch-vcs LICENSE= MIT LICENSE_FILE= ${WRKSRC}/LICENSE.txt +BUILD_DEPENDS= ${PYTHON_PKGNAMEPREFIX}hatchling>=1.1.0:devel/py-hatchling@${PY_FLAVOR} RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}hatchling>=1.1.0:devel/py-hatchling@${PY_FLAVOR} \ ${PYTHON_PKGNAMEPREFIX}setuptools_scm>=6.4.0:devel/py-setuptools_scm@${PY_FLAVOR} TEST_DEPENDS= git:devel/git USES= python:3.7+ -USE_PYTHON= autoplist concurrent distutils pytest +USE_PYTHON= autoplist concurrent pep517 pytest NO_ARCH= yes TEST_ENV= PYTHONPATH=${STAGEDIR}${PYTHON_SITELIBDIR} -post-patch: - @${RM} ${WRKSRC}/pyproject.toml - @${SED} -e 's|%%PORTVERSION%%|${PORTVERSION}|' ${FILESDIR}/setup.py > ${WRKSRC}/setup.py - .include diff --git a/devel/py-hatch-vcs/files/setup.py b/devel/py-hatch-vcs/files/setup.py deleted file mode 100644 index e3edabf836c6..000000000000 --- a/devel/py-hatch-vcs/files/setup.py +++ /dev/null @@ -1,33 +0,0 @@ -# -*- coding: utf-8 -*- -from setuptools import setup - -setup( - name='hatch-vcs', - version='%%PORTVERSION%%', - description='Hatch plugin for versioning with your preferred VCS', - long_description='# hatch-vcs\n\n| | |\n| --- | --- |\n| CI/CD | [![CI - Test](https://github.com/ofek/hatch-vcs/actions/workflows/test.yml/badge.svg)](https://github.com/ofek/hatch-vcs/actions/workflows/test.yml) [![CD - Build](https://github.com/ofek/hatch-vcs/actions/workflows/build.yml/badge.svg)](https://github.com/ofek/hatch-vcs/actions/workflows/build.yml) |\n| Package | [![PyPI - Version](https://img.shields.io/pypi/v/hatch-vcs.svg?logo=pypi&label=PyPI&logoColor=gold)](https://pypi.org/project/hatch-vcs/) [![PyPI - Python Version](https://img.shields.io/pypi/pyversions/hatch-vcs.svg?logo=python&label=Python&logoColor=gold)](https://pypi.org/project/hatch-vcs/) |\n| Meta | [![Hatch project](https://img.shields.io/badge/%F0%9F%A5%9A-Hatch-4051b5.svg)](https://github.com/pypa/hatch) [![code style - black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black) [![types - Mypy](https://img.shields.io/badge/types-Mypy-blue.svg)](https://gith ub.com/ambv/black) [![License - MIT](https://img.shields.io/badge/license-MIT-9400d3.svg)](https://spdx.org/licenses/) [![GitHub Sponsors](https://img.shields.io/github/sponsors/ofek?logo=GitHub%20Sponsors&style=social)](https://github.com/sponsors/ofek) |\n\n-----\n\nThis provides a plugin for [Hatch](https://github.com/pypa/hatch) that uses your preferred version control system (like Git) to determine project versions.\n\n**Table of Contents**\n\n- [Global dependency](#global-dependency)\n- [Version source](#version-source)\n - [Version source options](#version-source-options)\n - [Version source environment variables](#version-source-environment-variables)\n- [Build hook](#build-hook)\n - [Build hook options](#build-hook-options)\n - [Editable installs](#editable-installs)\n- [Metadata hook](#metadata-hook)\n - [Metadata hook options](#metadata-hook-options)\n - [URLs](#urls)\n - [Example](#example)\n- [License](#license)\n\n## Global dependency\n\nEnsure `hatch-vcs` is defined within the `build-system.requires` f! ield in your `pyproject.toml` file.\n\n```toml\n[build-system]\nrequires = ["hatchling", "hatch-vcs"]\nbuild-backend = "hatchling.build"\n```\n\n## Version source\n\nThe [version source plugin](https://hatch.pypa.io/latest/plugins/version-source/reference/) name is `vcs`.\n\n- ***pyproject.toml***\n\n ```toml\n [tool.hatch.version]\n source = "vcs"\n ```\n\n- ***hatch.toml***\n\n ```toml\n [version]\n source = "vcs"\n ```\n\n### Version source options\n\n| Option | Type | Default | Description |\n| --- | --- | --- | --- |\n| `tag-pattern` | `str` | see [code](https://github.com/pypa/setuptools_scm/blob/v6.4.0/src/setuptools_scm/config.py#L13) | A regular expression used to extract the version part from VCS tags. The pattern needs to contain either a single match group, or a group named `version`, that captures the actual version information. |\n| `fallback-version` | `str` | | The version that will be used if no other method for detecting the version is succe ssful. If not specified, unsuccessful version detection will raise an error. |\n| `raw-options` | `dict` | | A table of [`setuptools-scm` parameters](https://github.com/pypa/setuptools_scm#configuration-parameters) that will override any of the options listed above. The `write_to` and `write_to_template` parameters are ignored. |\n\n### Version source environment variables\n\n- `SETUPTOOLS_SCM_PRETEND_VERSION`: When defined and not empty, it\'s used as the primary source for the version, in which case it will be an unparsed string.\n\n## Build hook\n\nThe [build hook plugin](https://hatch.pypa.io/latest/plugins/build-hook/reference/) name is `vcs`.\n\n- ***pyproject.toml***\n\n ```toml\n [tool.hatch.build.hooks.vcs]\n version-file = "_version.py"\n ```\n\n- ***hatch.toml***\n\n ```toml\n [build.hooks.vcs]\n version-file = "_version.py"\n ```\n\nBuilding or installing when the latest tag is ``v1.2.3`` will generate the file\n\n- ***_version.py***\n\n ```pyt hon\n # coding: utf-8\n # file generat! ed by set! uptools_scm\n # don\'t change, don\'t track in version control\n __version__ = version = \'1.2.3\'\n __version_tuple__ = version_tuple = (1, 2, 3)\n ```\n\n### Build hook options\n\n| Option | Type | Default | Description |\n| --- | --- | --- | --- |\n| `version-file` | `str` | ***REQUIRED*** | The relative path to the file that gets updated with the current version. |\n| `template` | `str` | | The template used to overwrite the `version-file`. See the [code](https://github.com/pypa/setuptools_scm/blob/v6.4.0/src/setuptools_scm/__init__.py#L30-L39) for the default template for each file extension. |\n\n### Editable installs\n\nThe version file is only updated upon install or build. Thus the version number in an [editable install](https://pip.pypa.io/en/stable/topics/local-project-installs/#editable-installs) (Hatch\'s [dev mode](https://hatch.pypa.io/latest/config/build/#dev-mode)) will be incorrect if the version changes and the project is not rebuilt. An unsupported wo rkaround for keeping the version number up-to-date can be found at [hatch-vcs-footgun-example](https://github.com/maresb/hatch-vcs-footgun-example).\n\n## Metadata hook\n\n**Note:** only Git is supported\n\nThe [metadata hook plugin](https://hatch.pypa.io/latest/plugins/metadata-hook/reference/) name is `vcs`.\n\n- ***pyproject.toml***\n\n ```toml\n [tool.hatch.metadata.hooks.vcs]\n ```\n\n- ***hatch.toml***\n\n ```toml\n [metadata.hooks.vcs]\n ```\n\n### Metadata hook options\n\n#### URLs\n\nThe `urls` option is equivalent to [`project.urls`](https://hatch.pypa.io/latest/config/metadata/#urls) except that each URL supports [context formatting](https://hatch.pypa.io/latest/config/context/) with the following fields:\n\n- `commit_hash` - the latest commit hash\n\n### Example\n\n- ***pyproject.toml***\n\n ```toml\n [tool.hatch.metadata.hooks.vcs]\n Homepage = "https://www.example.com"\n source_archive = "https://github.com/org/repo/archive/{commit_hash}.z ip"\n ```\n\n- ***hatch.toml***\n\n ``! `toml\n ! [metadata.hooks.vcs]\n Homepage = "https://www.example.com"\n source_archive = "https://github.com/org/repo/archive/{commit_hash}.zip"\n ```\n\n## License\n\n`hatch-vcs` is distributed under the terms of the [MIT](https://spdx.org/licenses/MIT.html) license.\n', - author_email='Ofek Lev ', - classifiers=[ - 'Development Status :: 4 - Beta', - 'Programming Language :: Python', - 'Programming Language :: Python :: 3.7', - 'Programming Language :: Python :: 3.8', - 'Programming Language :: Python :: 3.9', - 'Programming Language :: Python :: 3.10', - 'Programming Language :: Python :: 3.11', - 'Programming Language :: Python :: Implementation :: CPython', - 'Programming Language :: Python :: Implementation :: PyPy', - ], - install_requires=[ - 'hatchling>=1.1.0', - 'setuptools-scm>=6.4.0', - ], - entry_points={ - 'hatch': [ - 'vcs = hatch_vcs.hooks', - ], - }, - packages=[ - 'hatch_vcs', - ], -)