unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
* [bug#58673] [PATCH] gnu: s3cmd: Fix program name in --help output.
@ 2022-10-21  3:21 Matthew James Kraai
  2022-10-23  8:24 ` [bug#58673] Updated patch Matthew James Kraai
  0 siblings, 1 reply; 3+ messages in thread
From: Matthew James Kraai @ 2022-10-21  3:21 UTC (permalink / raw)
  To: 58673; +Cc: Matthew James Kraai

* gnu/packages/python-xyz.scm (s3cmd)[arguments]: Add a new 'hide-wrapping
phase.
---
 gnu/packages/python-xyz.scm | 7 +++++++
 1 file changed, 7 insertions(+)

The Commands section of `s3cmd --help`'s output displays `.s3cmd-real` instead
of `s3cmd` in the commands (e.g., `.s3cmd-real mb s3://BUCKET`).  This makes
it display `s3cmd` instead (e.g., `s3cmd mb s3://BUCKET`).

diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index 32bd986a12..81fa89fec2 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -16222,6 +16222,13 @@ (define-public s3cmd
        (sha256
         (base32 "0rdgwwmmp8mdxc84bxq6k9a7v7z2qgc3df47djzs2b84gw81dglx"))))
     (build-system python-build-system)
+    (arguments
+     (list #:phases
+           #~(modify-phases %standard-phases
+               (add-after 'unpack 'hide-wrapping
+                 (lambda _
+                   (substitute* "s3cmd"
+                     (("optparser\\.get_prog_name\\(\\)") "\"s3cmd\"")))))))
     (inputs
      (list python-dateutil
            python-magic))
-- 
2.38.0





^ permalink raw reply related	[flat|nested] 3+ messages in thread

* [bug#58673] Updated patch
  2022-10-21  3:21 [bug#58673] [PATCH] gnu: s3cmd: Fix program name in --help output Matthew James Kraai
@ 2022-10-23  8:24 ` Matthew James Kraai
  2022-11-18 13:52   ` bug#58673: [PATCH] gnu: s3cmd: Fix program name in --help output Ludovic Courtès
  0 siblings, 1 reply; 3+ messages in thread
From: Matthew James Kraai @ 2022-10-23  8:24 UTC (permalink / raw)
  To: 58673

From 139a7cfe0398bb4bbe904ec58887f681de177657 Mon Sep 17 00:00:00 2001
From: Matthew James Kraai <kraai@ftbfs.org>
Date: Thu, 20 Oct 2022 20:16:00 -0700
Subject: [PATCH] gnu: s3cmd: Fix program name in output.

* gnu/packages/python-xyz.scm (s3cmd)[arguments]: Add a new 'hide-wrapping
phase.
---
 gnu/packages/python-xyz.scm | 9 +++++++++
 1 file changed, 9 insertions(+)

Here's an updated patch that also fixes the command name in messages displayed
by s3cmd.

diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm
index 32bd986a12..e795fa1838 100644
--- a/gnu/packages/python-xyz.scm
+++ b/gnu/packages/python-xyz.scm
@@ -16222,6 +16222,15 @@ (define-public s3cmd
        (sha256
         (base32 "0rdgwwmmp8mdxc84bxq6k9a7v7z2qgc3df47djzs2b84gw81dglx"))))
     (build-system python-build-system)
+    (arguments
+     (list #:phases
+           #~(modify-phases %standard-phases
+               (add-after 'unpack 'hide-wrapping
+                 (lambda _
+                   (substitute* "S3/MultiPart.py"
+                     (("sys\\.argv\\[0\\]") "\"s3cmd\""))
+                   (substitute* "s3cmd"
+                     (("optparser\\.get_prog_name\\(\\)") "\"s3cmd\"")))))))
     (inputs
      (list python-dateutil
            python-magic))
-- 
2.38.0




^ permalink raw reply related	[flat|nested] 3+ messages in thread

* bug#58673: [PATCH] gnu: s3cmd: Fix program name in --help output.
  2022-10-23  8:24 ` [bug#58673] Updated patch Matthew James Kraai
@ 2022-11-18 13:52   ` Ludovic Courtès
  0 siblings, 0 replies; 3+ messages in thread
From: Ludovic Courtès @ 2022-11-18 13:52 UTC (permalink / raw)
  To: Matthew James Kraai; +Cc: 58673-done

Hi,

Matthew James Kraai <kraai@ftbfs.org> skribis:

>>From 139a7cfe0398bb4bbe904ec58887f681de177657 Mon Sep 17 00:00:00 2001
> From: Matthew James Kraai <kraai@ftbfs.org>
> Date: Thu, 20 Oct 2022 20:16:00 -0700
> Subject: [PATCH] gnu: s3cmd: Fix program name in output.
>
> * gnu/packages/python-xyz.scm (s3cmd)[arguments]: Add a new 'hide-wrapping
> phase.

Applied, thanks!




^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2022-11-18 13:53 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-10-21  3:21 [bug#58673] [PATCH] gnu: s3cmd: Fix program name in --help output Matthew James Kraai
2022-10-23  8:24 ` [bug#58673] Updated patch Matthew James Kraai
2022-11-18 13:52   ` bug#58673: [PATCH] gnu: s3cmd: Fix program name in --help output Ludovic Courtès

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

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 read-only IMAP folder(s) and NNTP newsgroup(s).