Gentoo Archives: gentoo-commits

From: "Michał Górny" <mgorny@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-python/pgspecial/
Date: Sat, 04 Jun 2022 07:42:09
Message-Id: 1654328521.51f67a0fdced2bbb83b7e1d8391d7b9f5d2dd731.mgorny@gentoo
1 commit: 51f67a0fdced2bbb83b7e1d8391d7b9f5d2dd731
2 Author: Michał Górny <mgorny <AT> gentoo <DOT> org>
3 AuthorDate: Sat Jun 4 07:12:59 2022 +0000
4 Commit: Michał Górny <mgorny <AT> gentoo <DOT> org>
5 CommitDate: Sat Jun 4 07:42:01 2022 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=51f67a0f
7
8 dev-python/pgspecial: Bump to 2.0.0
9
10 Signed-off-by: Michał Górny <mgorny <AT> gentoo.org>
11
12 dev-python/pgspecial/Manifest | 1 +
13 dev-python/pgspecial/pgspecial-2.0.0.ebuild | 55 +++++++++++++++++++++++++++++
14 2 files changed, 56 insertions(+)
15
16 diff --git a/dev-python/pgspecial/Manifest b/dev-python/pgspecial/Manifest
17 index c70d36a2e2a4..1ab608246aad 100644
18 --- a/dev-python/pgspecial/Manifest
19 +++ b/dev-python/pgspecial/Manifest
20 @@ -1 +1,2 @@
21 DIST pgspecial-1.13.1.tar.gz 50269 BLAKE2B 0566a7c2d8ee1ea350e27a4283f56c4cb1360f23ac9fe0147358ff68f527907c47650466dd41ae9c68e8a1f8ba658e452a88db360a7066f5562b7f0c578b8b62 SHA512 4b8f0495451db40087327640edc4bf8c29997b4f501dc5af6d093ad880fc337050d651676ae8ff434da3564e773f9e89e6e7d6bf0d6cfb7b70d8b4beea73a347
22 +DIST pgspecial-2.0.0.gh.tar.gz 50098 BLAKE2B 3e4c2b85c8d0e31bdd6d61fd1dd8e9a54b68fef23017e2a11238018d63fff8ba93ee5f8f5f4679321b1a757b4a504d86d9740bea91c95f0312a31cf0135378fa SHA512 59dfbc83be3f263fdf9fdad425675624f2738357f2b3f29abc37b90df1bdae30bee6145faa65715a7a166a9e8ee66201cc5344e697ce0121ae7c6bf9bb3af012
23
24 diff --git a/dev-python/pgspecial/pgspecial-2.0.0.ebuild b/dev-python/pgspecial/pgspecial-2.0.0.ebuild
25 new file mode 100644
26 index 000000000000..80daceb18f18
27 --- /dev/null
28 +++ b/dev-python/pgspecial/pgspecial-2.0.0.ebuild
29 @@ -0,0 +1,55 @@
30 +# Copyright 1999-2022 Gentoo Authors
31 +# Distributed under the terms of the GNU General Public License v2
32 +
33 +EAPI=8
34 +
35 +DISTUTILS_USE_PEP517=setuptools
36 +PYTHON_COMPAT=( python3_{8..10} )
37 +
38 +inherit distutils-r1
39 +
40 +DESCRIPTION="Python implementation of PostgreSQL meta commands"
41 +HOMEPAGE="
42 + https://github.com/dbcli/pgspecial/
43 + https://pypi.org/project/pgspecial/
44 +"
45 +SRC_URI="
46 + https://github.com/dbcli/pgspecial/archive/v${PV}.tar.gz
47 + -> ${P}.gh.tar.gz
48 +"
49 +
50 +LICENSE="BSD MIT"
51 +SLOT="0"
52 +KEYWORDS="~amd64 ~x86"
53 +
54 +RDEPEND="
55 + >=dev-python/click-4.1[${PYTHON_USEDEP}]
56 + >=dev-python/configobj-5.0.6[${PYTHON_USEDEP}]
57 + >=dev-python/psycopg-3.0.10:0[${PYTHON_USEDEP}]
58 + >=dev-python/sqlparse-0.1.19[${PYTHON_USEDEP}]
59 +"
60 +BDEPEND="
61 + test? (
62 + >=dev-db/postgresql-8.1[server]
63 + )
64 +"
65 +
66 +distutils_enable_tests pytest
67 +
68 +DOCS=( License.txt README.rst changelog.rst )
69 +
70 +src_test() {
71 + local db=${T}/pgsql
72 +
73 + initdb --username=postgres -D "${db}" || die
74 + # TODO: random port
75 + pg_ctl -w -D "${db}" start \
76 + -o "-h '127.0.0.1' -p 5432 -k '${T}'" || die
77 + psql -h "${T}" -U postgres -d postgres \
78 + -c "ALTER ROLE postgres WITH PASSWORD 'postgres';" || die
79 + createdb -h "${T}" -U postgres _test_db || die
80 +
81 + distutils-r1_src_test
82 +
83 + pg_ctl -w -D "${db}" stop || die
84 +}