devel/py-http-prompt: Update to 2.1.0

- Sort RUN_DEPENDS
- Update prompt-toolkit patch [1]

Changes:	https://github.com/httpie/http-prompt/releases
Obtained from:	69439599ca [1]
This commit is contained in:
Po-Chuan Hsieh 2022-10-04 01:05:08 +08:00
parent 670a0ed24d
commit 7269675776
No known key found for this signature in database
GPG key ID: 9A4BD10F002DD04B
5 changed files with 35 additions and 41 deletions

View file

@ -1,6 +1,5 @@
PORTNAME= http-prompt
PORTVERSION= 1.0.0
PORTREVISION= 3
PORTVERSION= 2.1.0
CATEGORIES= devel python
MASTER_SITES= CHEESESHOP
PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX}
@ -13,14 +12,14 @@ LICENSE= MIT
LICENSE_FILE= ${WRKSRC}/LICENSE
RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}click>=5.0:devel/py-click@${PY_FLAVOR} \
${PYTHON_PKGNAMEPREFIX}httpie>=2.4.0:www/py-httpie@${PY_FLAVOR} \
${PYTHON_PKGNAMEPREFIX}parsimonious>=0.6.2:textproc/py-parsimonious@${PY_FLAVOR} \
${PYTHON_PKGNAMEPREFIX}prompt-toolkit2>=2.0.0<2.1.0:devel/py-prompt-toolkit2@${PY_FLAVOR} \
${PYTHON_PKGNAMEPREFIX}prompt-toolkit2>=2.0.0<3.0.0:devel/py-prompt-toolkit2@${PY_FLAVOR} \
${PYTHON_PKGNAMEPREFIX}pygments>=2.1.0:textproc/py-pygments@${PY_FLAVOR} \
${PYTHON_PKGNAMEPREFIX}six>=1.10.0:devel/py-six@${PY_FLAVOR} \
${PYTHON_PKGNAMEPREFIX}httpie>=0.9.2:www/py-httpie@${PY_FLAVOR}
${PYTHON_PKGNAMEPREFIX}yaml>=3.0:devel/py-yaml@${PY_FLAVOR} \
USES= python:3.6+
USE_PYTHON= autoplist distutils
USE_PYTHON= autoplist concurrent distutils
NO_ARCH= yes

View file

@ -1,3 +1,3 @@
TIMESTAMP = 1541542190
SHA256 (http-prompt-1.0.0.tar.gz) = 41c24349cb0ca279ddfbb9db97fb26c43d7ab448ab30fd485ba17c74c20606ad
SIZE (http-prompt-1.0.0.tar.gz) = 21364
TIMESTAMP = 1664767914
SHA256 (http-prompt-2.1.0.tar.gz) = eee71a00fed0b8a2a35bb338b269be7a20e8a1a6f6465a65561d76a21521e7f3
SIZE (http-prompt-2.1.0.tar.gz) = 22672

View file

@ -1,13 +0,0 @@
Obtained from: https://github.com/jonathanslenders/http-prompt/commit/34de86178d8ae2b478e0ad989222aab24dd4c046
--- http_prompt/utils.py.orig 2018-11-04 14:03:53 UTC
+++ http_prompt/utils.py
@@ -3,7 +3,7 @@ from __future__ import unicode_literals
import math
import re
-from prompt_toolkit.shortcuts import create_output
+from prompt_toolkit.output.defaults import create_output
from six.moves import range

View file

@ -1,9 +1,8 @@
Obtained from: https://github.com/jonathanslenders/http-prompt/commit/34de86178d8ae2b478e0ad989222aab24dd4c046
https://github.com/jonathanslenders/http-prompt/commit/d3d84de2aa7f3fce521e5ac63f4bbcf9a2166501
Obtained from: https://github.com/httpie/http-prompt/commit/69439599cac3ac243729ebe6be20b3964bb3a4dd
--- http_prompt/cli.py.orig 2018-11-04 14:03:53 UTC
--- http_prompt/cli.py.orig 2021-01-05 12:12:23 UTC
+++ http_prompt/cli.py
@@ -9,11 +9,11 @@ import click
@@ -13,11 +13,11 @@ import click
from httpie.plugins import FormatterPlugin # noqa, avoid cyclic import
from httpie.output.formatters.colors import Solarized256Style
@ -17,8 +16,8 @@ Obtained from: https://github.com/jonathanslenders/http-prompt/commit/34de86178d
+from prompt_toolkit.styles.pygments import style_from_pygments_cls
from pygments.styles import get_style_by_name
from pygments.util import ClassNotFound
from six.moves.http_cookies import SimpleCookie
@@ -135,7 +135,7 @@ def cli(spec, env, url, http_options):
@@ -140,7 +140,7 @@ def cli(spec, env, url, http_options):
style_class = get_style_by_name(cfg['command_style'])
except ClassNotFound:
style_class = Solarized256Style
@ -27,7 +26,7 @@ Obtained from: https://github.com/jonathanslenders/http-prompt/commit/34de86178d
listener = ExecutionListener(cfg)
@@ -159,7 +159,9 @@ def cli(spec, env, url, http_options):
@@ -164,7 +164,9 @@ def cli(spec, env, url, http_options):
text = prompt('%s> ' % context.url, completer=completer,
lexer=lexer, style=style, history=history,
auto_suggest=AutoSuggestFromHistory(),
@ -38,3 +37,24 @@ Obtained from: https://github.com/jonathanslenders/http-prompt/commit/34de86178d
except EOFError:
break # Control-D pressed
else:
--- http_prompt/utils.py.orig 2021-03-05 14:07:33 UTC
+++ http_prompt/utils.py
@@ -4,7 +4,7 @@ import math
import re
import shlex
-from prompt_toolkit.shortcuts import create_output
+from prompt_toolkit.output.defaults import create_output
RE_ANSI_ESCAPE = re.compile(r'\x1b[^m]*m')
--- requirements.txt.orig 2021-03-05 14:07:33 UTC
+++ requirements.txt
@@ -1,6 +1,6 @@
click>=5.0
httpie>=2.4.0
parsimonious>=0.6.2
-prompt-toolkit>=1.0.0,<2.0.0
+prompt-toolkit>=2.0.0,<3.0.0
Pygments>=2.1.0
PyYAML>=3.0

View file

@ -1,12 +0,0 @@
Obtained from: https://github.com/jonathanslenders/http-prompt/commit/34de86178d8ae2b478e0ad989222aab24dd4c046
--- requirements.txt.orig 2018-11-04 14:03:53 UTC
+++ requirements.txt
@@ -1,6 +1,6 @@
click>=5.0
httpie>=0.9.2
parsimonious>=0.6.2
-prompt-toolkit>=1.0.0,<2.0.0
+prompt-toolkit>=2.0.0,<2.1.0
Pygments>=2.1.0
six>=1.10.0