Gentoo Archives: gentoo-commits

From: Marek Szuba <marecki@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-vcs/pre-commit/
Date: Thu, 20 Jan 2022 22:14:15
Message-Id: 1642716844.8386649080b2000f1266636d6deedeac093ce45c.marecki@gentoo
1 commit: 8386649080b2000f1266636d6deedeac093ce45c
2 Author: Marek Szuba <marecki <AT> gentoo <DOT> org>
3 AuthorDate: Thu Jan 20 22:13:28 2022 +0000
4 Commit: Marek Szuba <marecki <AT> gentoo <DOT> org>
5 CommitDate: Thu Jan 20 22:14:04 2022 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=83866490
7
8 dev-vcs/pre-commit: add 2.17.0
9
10 Signed-off-by: Marek Szuba <marecki <AT> gentoo.org>
11
12 dev-vcs/pre-commit/Manifest | 1 +
13 dev-vcs/pre-commit/pre-commit-2.17.0.ebuild | 51 +++++++++++++++++++++++++++++
14 2 files changed, 52 insertions(+)
15
16 diff --git a/dev-vcs/pre-commit/Manifest b/dev-vcs/pre-commit/Manifest
17 index 53c31ee53a78..3cc696338bf0 100644
18 --- a/dev-vcs/pre-commit/Manifest
19 +++ b/dev-vcs/pre-commit/Manifest
20 @@ -1,2 +1,3 @@
21 DIST pre-commit-2.15.0.tar.gz 255545 BLAKE2B 8fbb1fd6b1298ff1c5a6884dae53c79d108e8c4b74d05d6be36d562327fd024432d60e6df4570217e1b3f4ad8e33ee4d0d54a5d940f4833a46d4e9cb59698b3c SHA512 b87985aa625509d7a21e31e5774f259c264ec74fef88fc5e290cbac0326cdbadc37ab54b5bf3048d815cf9bc6d4adb71619fcb84c955c1bc9741da8dfd34251c
22 DIST pre-commit-2.16.0.tar.gz 256930 BLAKE2B e515dcc9109c91cc7ab5ce60f662ebd62cce4f23e32676b7c295332c959fa10a34c320a197d15d7307b94aee53e7ade5da62aed8bbe122262db15d88d82e9757 SHA512 c9eb14a40e25e8408c2b2b5687eba4908d609bbb7bcf58a0153326696d272bca555156fd75f3ec5f0dec219aeeb4084df77f329f47cf190e40052c11e92fe185
23 +DIST pre-commit-2.17.0.tar.gz 261131 BLAKE2B 114fac379690ee4c1c60970a1b0fbcd20faea785837c174514c3fc3d247ec79f52fb5f14c96a762921395d682017a9cc406dc59b3042fc955cd65019fb781a3f SHA512 54b5af9088083ad0c57fab09c06c35bd5921b29348454fc8fc16081d3c6a2e0add13f8a18f06b7408a0e06babc5e15659b37ab53797edd3514d516059e2343a8
24
25 diff --git a/dev-vcs/pre-commit/pre-commit-2.17.0.ebuild b/dev-vcs/pre-commit/pre-commit-2.17.0.ebuild
26 new file mode 100644
27 index 000000000000..2794cad11571
28 --- /dev/null
29 +++ b/dev-vcs/pre-commit/pre-commit-2.17.0.ebuild
30 @@ -0,0 +1,51 @@
31 +# Copyright 1999-2022 Gentoo Authors
32 +# Distributed under the terms of the GNU General Public License v2
33 +
34 +EAPI=8
35 +
36 +PYTHON_COMPAT=( python3_{8..10} )
37 +DISTUTILS_SINGLE_IMPL=1
38 +DISTUTILS_USE_PEP517=setuptools
39 +PYTHON_REQ_USE="sqlite"
40 +
41 +inherit distutils-r1
42 +
43 +DESCRIPTION="A framework for managing and maintaining multi-language Git pre-commit hooks"
44 +HOMEPAGE="https://pre-commit.com/"
45 +SRC_URI="https://github.com/${PN}/${PN}/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz"
46 +
47 +LICENSE="MIT"
48 +SLOT="0"
49 +KEYWORDS="~amd64 ~hppa ~ppc ~ppc64 ~x86"
50 +
51 +RDEPEND="dev-vcs/git
52 + $(python_gen_cond_dep '
53 + >=dev-python/cfgv-2.0.0[${PYTHON_USEDEP}]
54 + >=dev-python/identify-1.0.0[${PYTHON_USEDEP}]
55 + >=dev-python/nodeenv-0.11.1[${PYTHON_USEDEP}]
56 + >=dev-python/pyyaml-5.1[${PYTHON_USEDEP}]
57 + dev-python/toml[${PYTHON_USEDEP}]
58 + >=dev-python/virtualenv-20.0.8[${PYTHON_USEDEP}]
59 + ')"
60 +BDEPEND="test? (
61 + $(python_gen_cond_dep '
62 + dev-python/pytest-env[${PYTHON_USEDEP}]
63 + dev-python/re-assert[${PYTHON_USEDEP}]
64 + ')
65 +)"
66 +
67 +DOCS=( CHANGELOG.md CONTRIBUTING.md README.md )
68 +
69 +# The former two require a boatload of dependencies (e.g. Conda, Go, R and more) in order to run
70 +# and while some of them do include "skip if not found" logic, most of them do not.
71 +# The latter consistently fail with
72 +# Calling "git rev-parse" fails with "fatal: not a git repository (or any of the parent directories): .git".
73 +# including with the sandbox disabled and when run manually with tox.
74 +EPYTEST_DESELECT=(
75 + tests/languages/
76 + tests/repository_test.py
77 + tests/main_test.py::test_all_cmds
78 + tests/main_test.py::test_try_repo
79 +)
80 +
81 +distutils_enable_tests pytest