Github messages for voidlinux
 help / color / mirror / Atom feed
From: jbenden <jbenden@users.noreply.github.com>
To: ml@inbox.vuxu.org
Subject: Re: [PR PATCH] [Updated] New package: python3-pre-commit-2.15.0_1.
Date: Mon, 06 Dec 2021 21:16:48 +0100	[thread overview]
Message-ID: <20211206201648.MlCbpxmwFaJOvTAmyE5t8RzLgji3ji5-_eHifZ6cYC4@z> (raw)
In-Reply-To: <gh-mailinglist-notifications-41a7ca26-5023-4802-975b-f1789d68868e-void-packages-33770@inbox.vuxu.org>

[-- Attachment #1: Type: text/plain, Size: 1058 bytes --]

There is an updated pull request by jbenden against master on the void-packages repository

https://github.com/jbenden/void-packages pre-commit
https://github.com/void-linux/void-packages/pull/33770

New package: python3-pre-commit-2.15.0_1.
#### General
- [x] This is a new package and it conforms to the [quality requirements](https://github.com/void-linux/void-packages/blob/master/Manual.md#quality-requirements)

#### Have the results of the proposed changes been tested?
- [x] I use the packages affected by the proposed changes on a regular basis and confirm this PR works for me
- [ ] I generally don't use the affected packages but briefly tested this PR

The primary package "python3-pre-commit" could also be named "pre-commit". Not sure which is preferred.

#### Notes:
- The `nodeenv` package has tests that fail in CI. I've marked them to be skipped in CI. Locally these tests pass on x86_64.
- The `pre-commit` release package has no tests.

A patch file from https://github.com/void-linux/void-packages/pull/33770.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-pre-commit-33770.patch --]
[-- Type: text/x-diff, Size: 7360 bytes --]

From c148cddd3226844503e81874a225342bd0bcf36f Mon Sep 17 00:00:00 2001
From: Joseph Benden <joe@benden.us>
Date: Wed, 27 Oct 2021 14:09:29 -0700
Subject: [PATCH 1/4] New package: python3-cfgv-3.3.1_1.

Signed-off-by: Joseph Benden <joe@benden.us>
---
 srcpkgs/python3-cfgv/template | 18 ++++++++++++++++++
 1 file changed, 18 insertions(+)
 create mode 100644 srcpkgs/python3-cfgv/template

diff --git a/srcpkgs/python3-cfgv/template b/srcpkgs/python3-cfgv/template
new file mode 100644
index 000000000000..9e1e97e20659
--- /dev/null
+++ b/srcpkgs/python3-cfgv/template
@@ -0,0 +1,18 @@
+# Template file for 'python3-cfgv'
+pkgname=python3-cfgv
+version=3.3.1
+revision=1
+wrksrc="cfgv-${version}"
+build_style=python3-module
+hostmakedepends="python3-setuptools"
+depends="python3"
+short_desc="Validate configuration and produce human readable error messages"
+maintainer="Joseph Benden <joe@benden.us>"
+license="MIT"
+homepage="https://github.com/asottile/cfgv"
+distfiles="${PYPI_SITE}/c/cfgv/cfgv-${version}.tar.gz"
+checksum=f5a830efb9ce7a445376bb66ec94c638a9787422f96264c98edc6bdeed8ab736
+
+post_install() {
+	vlicense LICENSE
+}

From 4ebf1202b17a4aa8f9db165897328cc924fd3b7e Mon Sep 17 00:00:00 2001
From: Joseph Benden <joe@benden.us>
Date: Wed, 27 Oct 2021 14:10:26 -0700
Subject: [PATCH 2/4] New package: python3-identify-2.3.1_1.

Signed-off-by: Joseph Benden <joe@benden.us>
---
 srcpkgs/python3-identify/template | 18 ++++++++++++++++++
 1 file changed, 18 insertions(+)
 create mode 100644 srcpkgs/python3-identify/template

diff --git a/srcpkgs/python3-identify/template b/srcpkgs/python3-identify/template
new file mode 100644
index 000000000000..6af581162d2f
--- /dev/null
+++ b/srcpkgs/python3-identify/template
@@ -0,0 +1,18 @@
+# Template file for 'python3-identify'
+pkgname=python3-identify
+version=2.3.1
+revision=1
+wrksrc="identify-${version}"
+build_style=python3-module
+hostmakedepends="python3-setuptools"
+depends="python3"
+short_desc="File identification library for Python"
+maintainer="Joseph Benden <joe@benden.us>"
+license="MIT"
+homepage="https://github.com/chriskuehl/identify"
+distfiles="${PYPI_SITE}/i/identify/identify-${version}.tar.gz"
+checksum=8a92c56893e9a4ce951f09a50489986615e3eba7b4c60610e0b25f93ca4487ba
+
+post_install() {
+	vlicense LICENSE
+}

From afca219741314f657c99b30bdbd03dfa5bcada49 Mon Sep 17 00:00:00 2001
From: Joseph Benden <joe@benden.us>
Date: Wed, 27 Oct 2021 14:32:17 -0700
Subject: [PATCH 3/4] New package: nodeenv-1.6.0_1.

Signed-off-by: Joseph Benden <joe@benden.us>
---
 .../nodeenv/patches/fix-i686-and-musl.patch   | 55 +++++++++++++++++++
 srcpkgs/nodeenv/template                      | 19 +++++++
 2 files changed, 74 insertions(+)
 create mode 100644 srcpkgs/nodeenv/patches/fix-i686-and-musl.patch
 create mode 100644 srcpkgs/nodeenv/template

diff --git a/srcpkgs/nodeenv/patches/fix-i686-and-musl.patch b/srcpkgs/nodeenv/patches/fix-i686-and-musl.patch
new file mode 100644
index 000000000000..fa75c0f7a6b7
--- /dev/null
+++ b/srcpkgs/nodeenv/patches/fix-i686-and-musl.patch
@@ -0,0 +1,55 @@
+--- a/tests/nodeenv_test.py.orig	2021-04-09 01:10:31.000000000 -0700
++++ b/tests/nodeenv_test.py	2021-11-06 15:08:23.169976189 -0700
+@@ -108,7 +108,7 @@ def test_mirror_option():
+             ('',
+              'https://nodejs.org/download/release/index.json')]
+     sys_type = sysconfig.get_config_var('HOST_GNU_TYPE')
+-    musl_type = ['x86_64-pc-linux-musl', 'x86_64-unknown-linux-musl']
++    musl_type = ['x86_64-pc-linux-musl', 'x86_64-unknown-linux-musl', 'i686-pc-linux-gnu', 'armv6l-unknown-linux-gnueabi']
+     # Check if running on musl system and delete last mirror if it is
+     if sys_type in musl_type:
+         urls.pop()
+--- a/nodeenv.py.orig	2021-04-09 01:10:31.000000000 -0700
++++ b/nodeenv.py	2021-12-06 12:55:47.748645252 -0700
+@@ -510,8 +510,21 @@ def get_root_url(version):
+         return src_base_url
+ 
+ 
++def is_armv6l_linux():
++    return sysconfig.get_config_var('HOST_GNU_TYPE') == 'armv6l-unknown-linux-gnueabi'
++
++
++def is_i686_linux():
++    return sysconfig.get_config_var('HOST_GNU_TYPE') == 'i686-pc-linux-gnu'
++
++
++def is_musl():
++    return str(sysconfig.get_config_var('HOST_GNU_TYPE')).endswith('-musl')
++
++
+ def is_x86_64_musl():
+-    return sysconfig.get_config_var('HOST_GNU_TYPE') == 'x86_64-pc-linux-musl'
++    return sysconfig.get_config_var('HOST_GNU_TYPE') == 'x86_64-pc-linux-musl' or \
++           sysconfig.get_config_var('HOST_GNU_TYPE') == 'x86_64-unknown-linux-musl'
+ 
+ 
+ def get_node_bin_url(version):
+@@ -1057,13 +1070,17 @@ def main():
+         else:
+             src_domain = opt.mirror
+     # use unofficial builds only if musl and no explicitly chosen mirror
+-    elif is_x86_64_musl():
++    elif is_x86_64_musl() or is_armv6l_linux() or is_i686_linux():
+         src_domain = 'unofficial-builds.nodejs.org'
+     else:
+         src_domain = 'nodejs.org'
+     if src_base_url is None:
+         src_base_url = 'https://%s/download/release' % src_domain
+ 
++    if opt.prebuilt and is_musl() and not is_x86_64_musl():
++        logger.error('No prebuilt Node.js for MUSL libc exists!')
++        exit(1)
++
+     if not opt.node or opt.node.lower() == 'latest':
+         opt.node = get_last_stable_node_version()
+     elif opt.node.lower() == 'lts':
diff --git a/srcpkgs/nodeenv/template b/srcpkgs/nodeenv/template
new file mode 100644
index 000000000000..dc8733bf4583
--- /dev/null
+++ b/srcpkgs/nodeenv/template
@@ -0,0 +1,19 @@
+# Template file for 'nodeenv'
+pkgname=nodeenv
+version=1.6.0
+revision=1
+wrksrc="nodeenv-${version}"
+build_style=python3-module
+makedepends="python3-setuptools"
+depends="make python3-setuptools"
+checkdepends="nodejs python3-coverage python3-mock python3-pytest which"
+short_desc="Node.js virtual environment builder"
+maintainer="Joseph Benden <joe@benden.us>"
+license="BSD-3-Clause"
+homepage="https://github.com/ekalinin/nodeenv"
+distfiles="https://github.com/ekalinin/nodeenv/archive/${version}.tar.gz"
+checksum=87b04b0832d38bd825e004e7c8ed82d75524efaa6b8a72e3a55088d93e4e17f7
+
+post_install() {
+	vlicense LICENSE
+}

From 506b514fc891d285c02412654e063ddeaf5a423f Mon Sep 17 00:00:00 2001
From: Joseph Benden <joe@benden.us>
Date: Wed, 27 Oct 2021 14:33:51 -0700
Subject: [PATCH 4/4] New package: pre-commit-2.15.0_1.

Signed-off-by: Joseph Benden <joe@benden.us>
---
 srcpkgs/pre-commit/template | 19 +++++++++++++++++++
 1 file changed, 19 insertions(+)
 create mode 100644 srcpkgs/pre-commit/template

diff --git a/srcpkgs/pre-commit/template b/srcpkgs/pre-commit/template
new file mode 100644
index 000000000000..855dff84d13f
--- /dev/null
+++ b/srcpkgs/pre-commit/template
@@ -0,0 +1,19 @@
+# Template file for 'pre-commit'
+pkgname=pre-commit
+version=2.15.0
+revision=1
+wrksrc="pre_commit-${version}"
+build_style=python3-module
+hostmakedepends="python3-setuptools"
+depends="nodeenv python3-cfgv python3-identify python3-yaml python3-toml"
+short_desc="Framework for multi-language pre-commit hooks"
+maintainer="Joseph Benden <joe@benden.us>"
+license="MIT"
+homepage="https://pre-commit.com/"
+distfiles="${PYPI_SITE}/p/pre-commit/pre_commit-${version}.tar.gz"
+checksum=3c25add78dbdfb6a28a651780d5c311ac40dd17f160eb3954a0c59da40a505a7
+make_check=no   # No tests available
+
+post_install() {
+	vlicense LICENSE
+}

  parent reply	other threads:[~2021-12-06 20:16 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-10-26 19:49 [PR PATCH] " jbenden
2021-10-26 20:30 ` [PR PATCH] [Updated] " jbenden
2021-10-26 20:44 ` jbenden
2021-10-27 16:33 ` Chocimier
2021-10-27 21:35 ` [PR PATCH] [Updated] " jbenden
2021-10-27 21:37 ` jbenden
2021-10-29 19:37 ` Chocimier
2021-10-29 20:19 ` jbenden
2021-11-03 21:08 ` [PR REVIEW] " Chocimier
2021-11-03 22:31 ` jbenden
2021-11-03 22:45 ` paper42
2021-11-06  4:05 ` [PR PATCH] [Updated] " jbenden
2021-11-06  4:07 ` jbenden
2021-11-06 18:56 ` [PR REVIEW] " jbenden
2021-11-06 20:05 ` Chocimier
2021-11-06 22:20 ` [PR PATCH] [Updated] " jbenden
2021-11-06 22:33 ` [PR REVIEW] " jbenden
2021-11-06 23:29 ` jbenden
2021-11-06 23:32 ` jbenden
2021-11-09  0:10 ` Chocimier
2021-12-06 20:16 ` jbenden [this message]
2021-12-06 20:20 ` jbenden
2021-12-08 17:29 ` [PR REVIEW] " Chocimier
2021-12-08 17:30 ` Chocimier
2021-12-08 18:52 ` [PR PATCH] [Updated] " jbenden
2021-12-28 23:46 ` jbenden
2021-12-29 23:13 ` [PR PATCH] [Merged]: " Chocimier

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20211206201648.MlCbpxmwFaJOvTAmyE5t8RzLgji3ji5-_eHifZ6cYC4@z \
    --to=jbenden@users.noreply.github.com \
    --cc=ml@inbox.vuxu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).