From cdc1eda9c1ad611dd737415be2790c8f44812f1c Mon Sep 17 00:00:00 2001 From: V3n3RiX Date: Sun, 12 Nov 2023 04:31:34 +0000 Subject: gentoo auto-resync : 12:11:2023 - 04:31:34 --- app-text/wgetpaste/Manifest | 8 +- .../files/wgetpaste-2.33-add-A-ansi.patch | 39 +++++ .../files/wgetpaste-2.33-added-quiet-flag.patch | 10 +- ...getpaste-2.33-change-arg-parsing-priority.patch | 95 ++++++++++++ ...etpaste-2.33-test_ansi-add-A-to-the-tests.patch | 171 +++++++++++++++++++++ app-text/wgetpaste/wgetpaste-2.33-r3.ebuild | 62 ++++++++ app-text/wgetpaste/wgetpaste-2.33-r4.ebuild | 63 -------- app-text/wgetpaste/wgetpaste-2.33-r5.ebuild | 66 ++++++++ 8 files changed, 444 insertions(+), 70 deletions(-) create mode 100644 app-text/wgetpaste/files/wgetpaste-2.33-add-A-ansi.patch create mode 100644 app-text/wgetpaste/files/wgetpaste-2.33-change-arg-parsing-priority.patch create mode 100644 app-text/wgetpaste/files/wgetpaste-2.33-test_ansi-add-A-to-the-tests.patch create mode 100644 app-text/wgetpaste/wgetpaste-2.33-r3.ebuild delete mode 100644 app-text/wgetpaste/wgetpaste-2.33-r4.ebuild create mode 100644 app-text/wgetpaste/wgetpaste-2.33-r5.ebuild (limited to 'app-text/wgetpaste') diff --git a/app-text/wgetpaste/Manifest b/app-text/wgetpaste/Manifest index 6f7859c245ee..62cd7a57bbeb 100644 --- a/app-text/wgetpaste/Manifest +++ b/app-text/wgetpaste/Manifest @@ -1,7 +1,11 @@ +AUX wgetpaste-2.33-add-A-ansi.patch 1326 BLAKE2B 346ef665d31ae2b38018d20235d09626e705fc4f83f00317c293f7cdc58be93b007859bf55246fa0d37d8b74459628d81f2207c204ad3cedd2e2ac7f3051a192 SHA512 1128c4046160e14143677741c825f8ff288a6708965f6d6496d10d3eec6f181bc096c691315e3043ee191d800dd3f020fc22e6c5a7bfde58b903c0d61b370d1f AUX wgetpaste-2.33-add-paste-gentoo-zip.patch 2202 BLAKE2B d0b487cc92a834250b422a9524378a7f35f2e32349a6394056e77bcb5bb01ae8d6d5097107c7a7fa6f705351c3529fadad20cb99284f5a03455d2cd2bac8ee4f SHA512 eab6567657189ad5c5abae65c410de47da613099c652f5311511f13e9dc515825f17d5ff5e9a3eef58ac24a36841e61a10b8a2a8c5a68c9456cca81707db7ca7 -AUX wgetpaste-2.33-added-quiet-flag.patch 2030 BLAKE2B c5bf1f3ddfb14209402c730c69889f32c45405b8f8b2cbda85f1c3b9e40507f902cae419e4a6598d268a32532afc0b516468b81196bae8244d626f50d87ebb2f SHA512 1f48b09a31a24c1df6b20afb38617fd463ed72d52ae9f5b71aea9156b8dbe4896a4a1f31267b99cf300861ed07dbe4b7fb0f08d939d3e27c2dfbea9a872f2217 +AUX wgetpaste-2.33-added-quiet-flag.patch 2030 BLAKE2B 129bd4e832a7e1d0270f8f57e1fa35b47a295054ef18eea2fd443df91850759ececc460276ae1e55ceba3bad85b4370ec475172bbc061dd65ae4a1172290c4e1 SHA512 79e059a0364075225b5900923c496ae1717052831e3ce373c871e21239fbe769d26ef1a51ffbb33af871475529dd96b3933c2a8e0f83718b8e9a1d172264149a +AUX wgetpaste-2.33-change-arg-parsing-priority.patch 2586 BLAKE2B 65a5f6e6e92453ad862ebf8a9ad654d3ffae2f0d4a9da52ada6b65653c0e84e2242ca0f4f3cc5cdb84125da03597bcb245c4a42aa3ff7823e5b4750c37722995 SHA512 bfe365b9e0c3d555e39a553d89cdc8b2a4bd13b40a726ac8208cbffac7cab84608f3e00110a76329719c26ec38a73153d6ed38f19c24a87c487b89bf098324a8 AUX wgetpaste-2.33-disable-sprunge.patch 790 BLAKE2B 9cd8c336072d7e2bff27a54d904ffa88331905dd8fe5a6a5d11c84c8fefc663bf24a481149bee8ff25f3d4140a81e6de5686ae97ffe545e77c52a2ea1c69d128 SHA512 179d3e38033d3f845c348c9a46fb40368c729fe721cc78580ed7b16ad507ead19595609998722c13423fdec6a1c9f2221fae34994840120f2ab2cdda65145d13 +AUX wgetpaste-2.33-test_ansi-add-A-to-the-tests.patch 5416 BLAKE2B ba849d311ba42a16ce6cfd120f3988637825bb1546482c34f7b5610f61b687e632736b79018e13828e361064c652c7adb3f54239753c1a7f7a1623c7a29af861 SHA512 6c19ed88c0cbc8ce9cecfcef3587e660f2223bc44022bc1f7411ada5ff1a90dd6b5128d033b5ff54f0ab23440145dae25f2f24661d5e7358bfd08ec332dff244 AUX wgetpaste-2.33-tests.patch 2742 BLAKE2B 3bb6c60de41ff4e428048816b093f40691de2a625e2a27a75b8db9f4e7333ab43778be704ddba01e2d5eb43a20f6ca6a83059f8bb2d04d08dc9d196901e53a17 SHA512 6d8a65215d4c1939c2f0acdd486171d37c4f1ef71b8ef6341fcf50db9cd057de1d616b3f3ac57820082d6fce1d8c75d72c8613865a0cf46df5fd3f5104716024 DIST wgetpaste-2.33.tar.xz 16408 BLAKE2B 78baebf4edb6e6340a73127099366d306359d02c0c1eab137822c56669da0609a5479940b4fb2accbc79978df091dcd34415876618e64aa556d1584f74773736 SHA512 9bf1f379316da372b4f69296b54f9a266dcf9fdaa2a8718165a2029571f4c2c0166304ffebeb2ec4657ea6f49087793f40d9da383f5da052bce0543c90ea13ab -EBUILD wgetpaste-2.33-r4.ebuild 1491 BLAKE2B aea885091777d8208c51bb559afc3ef0ab6d6790d56904f79f996ffcc58487daab0ed3eda759f1a3fceaf6d77b4fe30f6b55a88b38664e3fecd25f11e30cde92 SHA512 b0eadc4b0570c8602a177204688e98da8a8722f351212a50fc33ad0adf3e81f61fc0428cb5cad41442cf672a482e537207c9d67e0d3de6e7751b17edf39b8b10 +EBUILD wgetpaste-2.33-r3.ebuild 1442 BLAKE2B 4ba780c9c4dbbcd9c958c73b473a9eac89cd29e8b4a580a5888194c6aa58cb9fd1b5e4bd68c6c97f761b80a6f7325ffb1077f08e19ce4fd1b915af162d214917 SHA512 d9326673ce2332da4577d35432ce1b1b1ffbff30607818fbdcf554c0f9af8577317211ea840ca16b7726c1302f4ebdd0bc15f92231193419d28845dba398ec66 +EBUILD wgetpaste-2.33-r5.ebuild 1663 BLAKE2B 1cc9ce334866b04d9bfc3ece14cb24809e760f3764fa7c07e000df0946f9761915a4305e7c8fd513f6621ec1cf7e7ee1f481edb3ffbcb723dbdc41e550c8a50b SHA512 752ffaedc1a8b3ebe96779b29e786ab40fa7c8020b0ff6cb278bf1e19781db7da3883516f1d520bfc45a5e820177a46a5b96a9b6d6e591584e373ca9449f4cf3 MISC metadata.xml 566 BLAKE2B 1f63219976e414e688b0e8b5d0ce84dc4480af3e59ebbbe550d26ca5973ac22148b87d1b43304bbbfbcaba1731d14a6f7639b7352e2b77d1141f8dee6875d2ce SHA512 779b873177a5b294e6a140d8d658980469b50cdb1c65f6c4a387e8af82f996f109ed14ae208f8603cdfc80ac0f9f0a50ad00202e92c0f5c6aaea13d01ecf8862 diff --git a/app-text/wgetpaste/files/wgetpaste-2.33-add-A-ansi.patch b/app-text/wgetpaste/files/wgetpaste-2.33-add-A-ansi.patch new file mode 100644 index 000000000000..e55c8192dac7 --- /dev/null +++ b/app-text/wgetpaste/files/wgetpaste-2.33-add-A-ansi.patch @@ -0,0 +1,39 @@ +From 9614658e6a31bf1b318972008fd9fd1301e9d92f Mon Sep 17 00:00:00 2001 +From: Oskari Pirhonen +Date: Sun, 13 Aug 2023 14:32:34 -0500 +Subject: [PATCH 2/3] Add -A/--ansi + +Don't strip ANSI codes. +--- +See also: https://github.com/zlin/wgetpaste/pull/46 +- Oskari + + wgetpaste | 5 +++++ + 1 file changed, 5 insertions(+) + +diff --git a/wgetpaste b/wgetpaste +index 5f4152d..1e3ae35 100755 +--- a/wgetpaste ++++ b/wgetpaste +@@ -556,6 +556,8 @@ Options: + -X, --xpaste write resulting url to the X primary selection buffer (requires x11-misc/xclip) + -C, --xclippaste write resulting url to the X clipboard selection buffer (requires x11-misc/xclip) + -N, --no-ansi strip ANSI codes such as colors before pasting (requires app-text/ansifilter) ++ -A, --ansi don't strip ANSI codes ++ (useful for undoing NOANSI specified in a config file) + + -r, --raw show url for the raw paste (no syntax highlighting or html) + -t, --tee use tee to show what is being pasted +@@ -789,6 +791,9 @@ while [[ -n $1 ]]; do + -- ) + shift && getfilenames "$@" && break + ;; ++ -A | --ansi ) ++ NOANSI= ++ ;; + -c | --command ) + requiredarg "$@" + SOURCE="command" +-- +2.41.0 + diff --git a/app-text/wgetpaste/files/wgetpaste-2.33-added-quiet-flag.patch b/app-text/wgetpaste/files/wgetpaste-2.33-added-quiet-flag.patch index f8bac315d2f2..b56322430364 100644 --- a/app-text/wgetpaste/files/wgetpaste-2.33-added-quiet-flag.patch +++ b/app-text/wgetpaste/files/wgetpaste-2.33-added-quiet-flag.patch @@ -1,4 +1,4 @@ -From 75e68f79adaae7f50920e84a748b7ebb4a3a8a1d Mon Sep 17 00:00:00 2001 +From fa0bd6dd8b7bc21b292e4f94eaa4fbf71d5240f1 Mon Sep 17 00:00:00 2001 From: Richard-Rogalski Date: Mon, 6 Nov 2023 14:00:02 -0600 Subject: [PATCH] Added --quiet flag @@ -26,10 +26,10 @@ index c4703e5..63696ad 100644 '--debug[be very verbose]' \ '(--help -h)'{--help,-h}'[show help and exit]' \ diff --git a/wgetpaste b/wgetpaste -index fc0b559..d016515 100755 +index 1e3ae35..e38f9e5 100755 --- a/wgetpaste +++ b/wgetpaste -@@ -559,6 +559,7 @@ Options: +@@ -561,6 +561,7 @@ Options: -r, --raw show url for the raw paste (no syntax highlighting or html) -t, --tee use tee to show what is being pasted @@ -37,7 +37,7 @@ index fc0b559..d016515 100755 -v, --verbose show wget stderr output if no url is received --completions emit output suitable for shell completions (only affects --list-*) --debug be *very* verbose (implies -v) -@@ -657,7 +658,7 @@ showexpirations() { +@@ -659,7 +660,7 @@ showexpirations() { } showurl() { @@ -46,7 +46,7 @@ index fc0b559..d016515 100755 echo "$1" [[ $XPASTE ]] && x_paste "$1" primary [[ $XCLIPPASTE ]] && x_paste "$1" clipboard -@@ -809,6 +810,9 @@ while [[ -n $1 ]]; do +@@ -841,6 +842,9 @@ while [[ -n $1 ]]; do -N | --no-ansi ) NOANSI=0 ;; diff --git a/app-text/wgetpaste/files/wgetpaste-2.33-change-arg-parsing-priority.patch b/app-text/wgetpaste/files/wgetpaste-2.33-change-arg-parsing-priority.patch new file mode 100644 index 000000000000..144d622f1243 --- /dev/null +++ b/app-text/wgetpaste/files/wgetpaste-2.33-change-arg-parsing-priority.patch @@ -0,0 +1,95 @@ +From cfe7dcd8a0e40b8c18556aad0b657f431c90505a Mon Sep 17 00:00:00 2001 +From: Oskari Pirhonen +Date: Sun, 13 Aug 2023 14:25:35 -0500 +Subject: [PATCH 1/3] Change arg parsing priority + +Read config files before parsing CLI args. Allows all options to be set +via config and overridden on the CLI. +--- +See also: https://github.com/zlin/wgetpaste/pull/46 +- Oskari + + wgetpaste | 53 ++++++++++++++++++++++++++++------------------------- + 1 file changed, 28 insertions(+), 25 deletions(-) + +diff --git a/wgetpaste b/wgetpaste +index fc0b559..5f4152d 100755 +--- a/wgetpaste ++++ b/wgetpaste +@@ -720,7 +720,32 @@ geturl() { + fi | tail -n1 + } + +-### read cli options ++# read the config files ++load_configs() { ++ if [[ ! $IGNORECONFIGS ]]; then ++ # compatibility code ++ local f deprecated= ++ for f in {/etc/,~/.}wgetpaste{.d/*.bash,}; do ++ if [[ -f $f ]]; then ++ if [[ -z $deprecated ]]; then ++ echo "The config files for wgetpaste have changed to *.conf.$N" >&2 ++ deprecated=0 ++ fi ++ echo "Please move ${f} to ${f%.bash}.conf" >&2 ++ source "$f" || die "Failed to source $f" ++ fi ++ done ++ [[ -n $deprecated ]] && echo >&2 ++ # new locations override old ones in case they collide ++ for f in {/etc/,~/.}wgetpaste{.d/*,}.conf; do ++ if [[ -f $f ]]; then ++ source "$f" || die "Failed to source $f" ++ fi ++ done ++ fi ++} ++ ++### get runtime options + + # separate groups of short options. replace --foo=bar with --foo bar + while [[ -n $1 ]]; do +@@ -756,6 +781,8 @@ done + # set the separated options as input options. + set -- "${ARGS[@]}" + ++load_configs ++ + while [[ -n $1 ]]; do + ((args=1)) + case "$1" in +@@ -859,30 +886,6 @@ if [[ $NOANSI ]]; then + fi + + ### defaults +-load_configs() { +- if [[ ! $IGNORECONFIGS ]]; then +- # compatibility code +- local f deprecated= +- for f in {/etc/,~/.}wgetpaste{.d/*.bash,}; do +- if [[ -f $f ]]; then +- if [[ -z $deprecated ]]; then +- echo "The config files for wgetpaste have changed to *.conf.$N" >&2 +- deprecated=0 +- fi +- echo "Please move ${f} to ${f%.bash}.conf" >&2 +- source "$f" || die "Failed to source $f" +- fi +- done +- [[ -n $deprecated ]] && echo >&2 +- # new locations override old ones in case they collide +- for f in {/etc/,~/.}wgetpaste{.d/*,}.conf; do +- if [[ -f $f ]]; then +- source "$f" || die "Failed to source $f" +- fi +- done +- fi +-} +-load_configs + [[ $SERVICESET ]] && verifyservice "$SERVICESET" && SERVICE=$(escape "$SERVICESET") + DEFAULT_NICK=${DEFAULT_NICK:-$(whoami)} || die "whoami failed" + DEFAULT_SERVICE=${DEFAULT_SERVICE:-bpaste} +-- +2.41.0 + diff --git a/app-text/wgetpaste/files/wgetpaste-2.33-test_ansi-add-A-to-the-tests.patch b/app-text/wgetpaste/files/wgetpaste-2.33-test_ansi-add-A-to-the-tests.patch new file mode 100644 index 000000000000..14e8f2f6482a --- /dev/null +++ b/app-text/wgetpaste/files/wgetpaste-2.33-test_ansi-add-A-to-the-tests.patch @@ -0,0 +1,171 @@ +From a1c0782e828bc5f0fc8b79d0131f1847c5e7b359 Mon Sep 17 00:00:00 2001 +From: Oskari Pirhonen +Date: Sun, 13 Aug 2023 14:52:20 -0500 +Subject: [PATCH 3/3] test_ansi: add -A to the tests + +--- +See also: https://github.com/zlin/wgetpaste/pull/46 +- Oskari + + test/test_ansi.sh | 92 +++++++++++++++++++++++++++++++++++++++++------ + 1 file changed, 81 insertions(+), 11 deletions(-) + +diff --git a/test/test_ansi.sh b/test/test_ansi.sh +index 23b27a8..e1e95f0 100755 +--- a/test/test_ansi.sh ++++ b/test/test_ansi.sh +@@ -94,8 +94,8 @@ fi + + # Paste stuff. Use a short timeout between requests (we're friendly after all!) + sleep 1 +-echo -n "Pasting command output (cat): " +-ERROR_LOG="$DL_DIR/command-error.log" ++echo -n "Pasting command output with ANSI stripping (cat): " ++ERROR_LOG="$DL_DIR/command-noansi-error.log" + URL="$("$TEST_DIR"/../wgetpaste -N -r -s "$WORKING" -v -c "cat $ANSI_FILE" 2>"$ERROR_LOG")" + if [ $? -ne 0 ]; then + echo "FAILED!" +@@ -104,7 +104,7 @@ else + echo "SUCCESS!" + + echo -n "Downloading: " +- if ! (wget -q "$URL" -O "$DL_DIR/command.txt" 2>>"$ERROR_LOG"); then ++ if ! (wget -q "$URL" -O "$DL_DIR/command-noansi.txt" 2>>"$ERROR_LOG"); then + echo "FAILED!" + FAILED_PASTE=$((FAILED_PASTE + 1)) + else +@@ -112,13 +112,35 @@ else + rm "$ERROR_LOG" + + echo "Removing 'command run' header" +- sed -i -e '1d' "$DL_DIR/command.txt" ++ sed -i -e '1d' "$DL_DIR/command-noansi.txt" ++ fi ++fi ++sleep 1 ++echo -n "Pasting command output without ANSI stripping (cat): " ++ERROR_LOG="$DL_DIR/command-ansi-error.log" ++URL="$("$TEST_DIR"/../wgetpaste -A -r -s "$WORKING" -v -c "cat $ANSI_FILE" 2>"$ERROR_LOG")" ++if [ $? -ne 0 ]; then ++ echo "FAILED!" ++ FAILED_PASTE=$((FAILED_PASTE + 1)) ++else ++ echo "SUCCESS!" ++ ++ echo -n "Downloading: " ++ if ! (wget -q "$URL" -O "$DL_DIR/command-ansi.txt" 2>>"$ERROR_LOG"); then ++ echo "FAILED!" ++ FAILED_PASTE=$((FAILED_PASTE + 1)) ++ else ++ echo "SUCCESS" ++ rm "$ERROR_LOG" ++ ++ echo "Removing 'command run' header" ++ sed -i -e '1d' "$DL_DIR/command-ansi.txt" + fi + fi + + sleep 1 +-echo -n "Pasting stdin (cat | wgetpaste): " +-ERROR_LOG="$DL_DIR/stdin-error.log" ++echo -n "Pasting stdin with ANSI stripping (cat | wgetpaste): " ++ERROR_LOG="$DL_DIR/stdin-noansi-error.log" + URL="$(cat "$ANSI_FILE" | "$TEST_DIR"/../wgetpaste -N -r -s "$WORKING" -v 2>"$ERROR_LOG")" + if [ $? -ne 0 ]; then + echo "FAILED!" +@@ -127,7 +149,26 @@ else + echo "SUCCESS!" + + echo -n "Downloading: " +- if ! (wget -q "$URL" -O "$DL_DIR/stdin.txt" 2>>"$ERROR_LOG"); then ++ if ! (wget -q "$URL" -O "$DL_DIR/stdin-noansi.txt" 2>>"$ERROR_LOG"); then ++ echo "FAILED!" ++ FAILED_PASTE=$((FAILED_PASTE + 1)) ++ else ++ echo "SUCCESS!" ++ rm "$ERROR_LOG" ++ fi ++fi ++sleep 1 ++echo -n "Pasting stdin without ANSI stripping (cat | wgetpaste): " ++ERROR_LOG="$DL_DIR/stdin-ansi-error.log" ++URL="$(cat "$ANSI_FILE" | "$TEST_DIR"/../wgetpaste -A -r -s "$WORKING" -v 2>"$ERROR_LOG")" ++if [ $? -ne 0 ]; then ++ echo "FAILED!" ++ FAILED_PASTE=$((FAILED_PASTE + 1)) ++else ++ echo "SUCCESS!" ++ ++ echo -n "Downloading: " ++ if ! (wget -q "$URL" -O "$DL_DIR/stdin-ansi.txt" 2>>"$ERROR_LOG"); then + echo "FAILED!" + FAILED_PASTE=$((FAILED_PASTE + 1)) + else +@@ -137,8 +178,8 @@ else + fi + + sleep 1 +-echo -n "Pasting a file: " +-ERROR_LOG="$DL_DIR/file-error.log" ++echo -n "Pasting a file with ANSI stripping: " ++ERROR_LOG="$DL_DIR/file-noansi-error.log" + URL="$("$TEST_DIR"/../wgetpaste -N -r -s "$WORKING" -v "$ANSI_FILE" 2>"$ERROR_LOG")" + if [ $? -ne 0 ]; then + echo "FAILED!" +@@ -147,7 +188,26 @@ else + echo "SUCCESS!" + + echo -n "Downloading: " +- if ! (wget -q "$URL" -O "$DL_DIR/file.txt" 2>>"$ERROR_LOG"); then ++ if ! (wget -q "$URL" -O "$DL_DIR/file-noansi.txt" 2>>"$ERROR_LOG"); then ++ echo "FAILED!" ++ FAILED_PASTE=$((FAILED_PASTE + 1)) ++ else ++ echo "SUCCESS!" ++ rm "$ERROR_LOG" ++ fi ++fi ++sleep 1 ++echo -n "Pasting a file without ANSI stripping: " ++ERROR_LOG="$DL_DIR/file-ansi-error.log" ++URL="$("$TEST_DIR"/../wgetpaste -A -r -s "$WORKING" -v "$ANSI_FILE" 2>"$ERROR_LOG")" ++if [ $? -ne 0 ]; then ++ echo "FAILED!" ++ FAILED_PASTE=$((FAILED_PASTE + 1)) ++else ++ echo "SUCCESS!" ++ ++ echo -n "Downloading: " ++ if ! (wget -q "$URL" -O "$DL_DIR/file-ansi.txt" 2>>"$ERROR_LOG"); then + echo "FAILED!" + FAILED_PASTE=$((FAILED_PASTE + 1)) + else +@@ -157,7 +217,7 @@ else + fi + + # Compare downloaded files +-for dl_file in "$DL_DIR"/*.txt; do ++for dl_file in "$DL_DIR"/*-noansi.txt; do + echo -n "Testing file $dl_file: " + # Ignore missing trailing newline and extra empty lines in downloaded file + if (diff -q -Z -B "$NOANSI_FILE" "$dl_file" &>/dev/null); then +@@ -167,6 +227,16 @@ for dl_file in "$DL_DIR"/*.txt; do + DL_MISMATCH=$((DL_MISMATCH + 1)) + fi + done ++for dl_file in "$DL_DIR"/*-ansi.txt; do ++ echo -n "Testing file $dl_file: " ++ # Ignore missing trailing newline and extra empty lines in downloaded file ++ if (diff -q -Z -B "$ANSI_FILE" "$dl_file" &>/dev/null); then ++ echo "SUCCESS!" ++ else ++ echo "FAILED!" ++ DL_MISMATCH=$((DL_MISMATCH + 1)) ++ fi ++done + + echo "Total failed pastes: $FAILED_PASTE" + echo "Total mismatches: $DL_MISMATCH" +-- +2.41.0 + diff --git a/app-text/wgetpaste/wgetpaste-2.33-r3.ebuild b/app-text/wgetpaste/wgetpaste-2.33-r3.ebuild new file mode 100644 index 000000000000..89f63061351c --- /dev/null +++ b/app-text/wgetpaste/wgetpaste-2.33-r3.ebuild @@ -0,0 +1,62 @@ +# Copyright 1999-2023 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit optfeature + +DESCRIPTION="Command-line interface to various pastebins" +HOMEPAGE="https://github.com/zlin/wgetpaste" +SRC_URI="https://github.com/zlin/wgetpaste/releases/download/${PV}/${P}.tar.xz" + +LICENSE="MIT" +SLOT="0" +KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~amd64-linux ~x86-linux ~x64-macos" +IUSE="+ssl" + +PROPERTIES="test_network" +RESTRICT="test" + +RDEPEND="net-misc/wget[ssl?]" + +PATCHES=( + "${FILESDIR}"/${PN}-2.33-tests.patch + "${FILESDIR}"/${PN}-2.33-disable-sprunge.patch + "${FILESDIR}"/${PN}-2.33-add-paste-gentoo-zip.patch +) + +src_prepare() { + default + + sed -i -e "s:/etc:\"${EPREFIX}\"/etc:g" wgetpaste || die +} + +src_test() { + test/test.sh || die +} + +src_install() { + dobin ${PN} + insinto /usr/share/zsh/site-functions + doins _wgetpaste +} + +pkg_postinst() { + optfeature "ANSI (color code) stripping support" app-text/ansifilter + optfeature "xclip support" x11-misc/xclip + + if [[ -n ${REPLACING_VERSIONS} ]]; then + local old + + for old in ${REPLACING_VERSIONS}; do + if ver_test ${old} -lt '2.33-r2'; then + ewarn + ewarn "Sprunge is dead and the service has been dropped from the code. Remove or" + ewarn "replace sprunge as the default service in the system or user wgetpaste" + ewarn "config if applicable." + ewarn + break + fi + done + fi +} diff --git a/app-text/wgetpaste/wgetpaste-2.33-r4.ebuild b/app-text/wgetpaste/wgetpaste-2.33-r4.ebuild deleted file mode 100644 index 4a7f3ee27a86..000000000000 --- a/app-text/wgetpaste/wgetpaste-2.33-r4.ebuild +++ /dev/null @@ -1,63 +0,0 @@ -# Copyright 1999-2023 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=8 - -inherit optfeature - -DESCRIPTION="Command-line interface to various pastebins" -HOMEPAGE="https://github.com/zlin/wgetpaste" -SRC_URI="https://github.com/zlin/wgetpaste/releases/download/${PV}/${P}.tar.xz" - -LICENSE="MIT" -SLOT="0" -KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~amd64-linux ~x86-linux ~x64-macos" -IUSE="+ssl" - -PROPERTIES="test_network" -RESTRICT="test" - -RDEPEND="net-misc/wget[ssl?]" - -PATCHES=( - "${FILESDIR}"/${PN}-2.33-tests.patch - "${FILESDIR}"/${PN}-2.33-disable-sprunge.patch - "${FILESDIR}"/${PN}-2.33-add-paste-gentoo-zip.patch - "${FILESDIR}"/${PN}-2.33-added-quiet-flag.patch -) - -src_prepare() { - default - - sed -i -e "s:/etc:\"${EPREFIX}\"/etc:g" wgetpaste || die -} - -src_test() { - test/test.sh || die -} - -src_install() { - dobin ${PN} - insinto /usr/share/zsh/site-functions - doins _wgetpaste -} - -pkg_postinst() { - optfeature "ANSI (color code) stripping support" app-text/ansifilter - optfeature "xclip support" x11-misc/xclip - - if [[ -n ${REPLACING_VERSIONS} ]]; then - local old - - for old in ${REPLACING_VERSIONS}; do - if ver_test ${old} -lt '2.33-r2'; then - ewarn - ewarn "Sprunge is dead and the service has been dropped from the code. Remove or" - ewarn "replace sprunge as the default service in the system or user wgetpaste" - ewarn "config if applicable." - ewarn - break - fi - done - fi -} diff --git a/app-text/wgetpaste/wgetpaste-2.33-r5.ebuild b/app-text/wgetpaste/wgetpaste-2.33-r5.ebuild new file mode 100644 index 000000000000..6c78bad4e65a --- /dev/null +++ b/app-text/wgetpaste/wgetpaste-2.33-r5.ebuild @@ -0,0 +1,66 @@ +# Copyright 1999-2023 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit optfeature + +DESCRIPTION="Command-line interface to various pastebins" +HOMEPAGE="https://github.com/zlin/wgetpaste" +SRC_URI="https://github.com/zlin/wgetpaste/releases/download/${PV}/${P}.tar.xz" + +LICENSE="MIT" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~x64-macos" +IUSE="+ssl" + +PROPERTIES="test_network" +RESTRICT="test" + +RDEPEND="net-misc/wget[ssl?]" + +PATCHES=( + "${FILESDIR}"/${PN}-2.33-tests.patch + "${FILESDIR}"/${PN}-2.33-disable-sprunge.patch + "${FILESDIR}"/${PN}-2.33-add-paste-gentoo-zip.patch + "${FILESDIR}"/${PN}-2.33-change-arg-parsing-priority.patch + "${FILESDIR}"/${PN}-2.33-add-A-ansi.patch + "${FILESDIR}"/${PN}-2.33-test_ansi-add-A-to-the-tests.patch + "${FILESDIR}"/${PN}-2.33-added-quiet-flag.patch +) + +src_prepare() { + default + + sed -i -e "s:/etc:\"${EPREFIX}\"/etc:g" wgetpaste || die +} + +src_test() { + test/test.sh || die +} + +src_install() { + dobin ${PN} + insinto /usr/share/zsh/site-functions + doins _wgetpaste +} + +pkg_postinst() { + optfeature "ANSI (color code) stripping support" app-text/ansifilter + optfeature "xclip support" x11-misc/xclip + + if [[ -n ${REPLACING_VERSIONS} ]]; then + local old + + for old in ${REPLACING_VERSIONS}; do + if ver_test ${old} -lt '2.33-r2'; then + ewarn + ewarn "Sprunge is dead and the service has been dropped from the code. Remove or" + ewarn "replace sprunge as the default service in the system or user wgetpaste" + ewarn "config if applicable." + ewarn + break + fi + done + fi +} -- cgit v1.2.3