git: a104e33d54e5 - main - net/py-url-normalize: Add py-url-normalize 1.4.3

From: Po-Chuan Hsieh <sunpoet_at_FreeBSD.org>
Date: Sat, 16 Apr 2022 04:20:52 UTC
The branch main has been updated by sunpoet:

URL: https://cgit.FreeBSD.org/ports/commit/?id=a104e33d54e5ee3683089203bb520769af9c33c5

commit a104e33d54e5ee3683089203bb520769af9c33c5
Author:     Po-Chuan Hsieh <sunpoet@FreeBSD.org>
AuthorDate: 2022-04-16 03:39:12 +0000
Commit:     Po-Chuan Hsieh <sunpoet@FreeBSD.org>
CommitDate: 2022-04-16 04:19:03 +0000

    net/py-url-normalize: Add py-url-normalize 1.4.3
    
    URI Normalization function:
    - Take care of IDN domains.
    - Always provide the URI scheme in lowercase characters.
    - Always provide the host, if any, in lowercase characters.
    - Only perform percent-encoding where it is essential.
    - Always use uppercase A-through-F characters when percent-encoding.
    - Prevent dot-segments appearing in non-relative URI paths.
    - For schemes that define a default authority, use an empty authority if the
      default is desired.
    - For schemes that define an empty path to be equivalent to a path of "/", use
      "/".
    - For schemes that define a port, use an empty port if the default is desired
    - All portions of the URI must be utf-8 encoded NFC from Unicode strings
    
    WWW: https://github.com/niksite/url-normalize
---
 net/Makefile                   |  1 +
 net/py-url-normalize/Makefile  | 22 ++++++++++++++++++++++
 net/py-url-normalize/distinfo  |  3 +++
 net/py-url-normalize/pkg-descr | 15 +++++++++++++++
 4 files changed, 41 insertions(+)

diff --git a/net/Makefile b/net/Makefile
index b1f253b9369e..d17143213560 100644
--- a/net/Makefile
+++ b/net/Makefile
@@ -1153,6 +1153,7 @@
     SUBDIR += py-txrestapi
     SUBDIR += py-uritemplate
     SUBDIR += py-uritools
+    SUBDIR += py-url-normalize
     SUBDIR += py-urlextract
     SUBDIR += py-urllib3
     SUBDIR += py-whois
diff --git a/net/py-url-normalize/Makefile b/net/py-url-normalize/Makefile
new file mode 100644
index 000000000000..72b5872aca2a
--- /dev/null
+++ b/net/py-url-normalize/Makefile
@@ -0,0 +1,22 @@
+# Created by: Po-Chuan Hsieh <sunpoet@FreeBSD.org>
+
+PORTNAME=	url-normalize
+PORTVERSION=	1.4.3
+CATEGORIES=	net python
+MASTER_SITES=	CHEESESHOP
+PKGNAMEPREFIX=	${PYTHON_PKGNAMEPREFIX}
+
+MAINTAINER=	sunpoet@FreeBSD.org
+COMMENT=	URL normalization for Python
+
+LICENSE=	MIT
+LICENSE_FILE=	${WRKSRC}/LICENSE
+
+RUN_DEPENDS=	${PYTHON_PKGNAMEPREFIX}six>=0:devel/py-six@${PY_FLAVOR}
+
+USES=		python:3.6+
+USE_PYTHON=	autoplist concurrent distutils
+
+NO_ARCH=	yes
+
+.include <bsd.port.mk>
diff --git a/net/py-url-normalize/distinfo b/net/py-url-normalize/distinfo
new file mode 100644
index 000000000000..5a9c8d563d0c
--- /dev/null
+++ b/net/py-url-normalize/distinfo
@@ -0,0 +1,3 @@
+TIMESTAMP = 1649423650
+SHA256 (url-normalize-1.4.3.tar.gz) = d23d3a070ac52a67b83a1c59a0e68f8608d1cd538783b401bc9de2c0fac999b2
+SIZE (url-normalize-1.4.3.tar.gz) = 6024
diff --git a/net/py-url-normalize/pkg-descr b/net/py-url-normalize/pkg-descr
new file mode 100644
index 000000000000..6a313b01ed1a
--- /dev/null
+++ b/net/py-url-normalize/pkg-descr
@@ -0,0 +1,15 @@
+URI Normalization function:
+- Take care of IDN domains.
+- Always provide the URI scheme in lowercase characters.
+- Always provide the host, if any, in lowercase characters.
+- Only perform percent-encoding where it is essential.
+- Always use uppercase A-through-F characters when percent-encoding.
+- Prevent dot-segments appearing in non-relative URI paths.
+- For schemes that define a default authority, use an empty authority if the
+  default is desired.
+- For schemes that define an empty path to be equivalent to a path of "/", use
+  "/".
+- For schemes that define a port, use an empty port if the default is desired
+- All portions of the URI must be utf-8 encoded NFC from Unicode strings
+
+WWW: https://github.com/niksite/url-normalize