GNU bug report logs -
#28327
[PATCH] gnu: Add emacs-bash-completion.
Previous Next
Reported by: Jan Nieuwenhuizen <janneke <at> gnu.org>
Date: Sat, 2 Sep 2017 09:12:01 UTC
Severity: normal
Tags: patch
Done: Jan Nieuwenhuizen <janneke <at> gnu.org>
Bug is archived. No further changes may be made.
To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 28327 in the body.
You can then email your comments to 28327 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
guix-patches <at> gnu.org
:
bug#28327
; Package
guix-patches
.
(Sat, 02 Sep 2017 09:12:02 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Jan Nieuwenhuizen <janneke <at> gnu.org>
:
New bug report received and forwarded. Copy sent to
guix-patches <at> gnu.org
.
(Sat, 02 Sep 2017 09:12:02 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
---
gnu/packages/emacs.scm | 25 +++++++++++++++++++++++++
1 file changed, 25 insertions(+)
diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm
index 612126eb3..f6165ba54 100644
--- a/gnu/packages/emacs.scm
+++ b/gnu/packages/emacs.scm
@@ -59,6 +59,7 @@
#:use-module (guix build-system trivial)
#:use-module (gnu packages)
#:use-module (gnu packages audio)
+ #:use-module (gnu packages bash)
#:use-module (gnu packages code)
#:use-module (gnu packages guile)
#:use-module (gnu packages gtk)
@@ -5444,3 +5445,27 @@ key. Optionally, a mouse pop-up can be added by binding
version of Idris, and some features may rely on the latest Git version of
Idris.")
(license license:gpl3+)))
+
+(define-public emacs-batch-completion
+ (package
+ (name "emacs-bash-completion")
+ (version "20170901.1445")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (string-append
+ "http://melpa.org/packages/bash-completion-"
+ version
+ ".tar"))
+ (sha256
+ (base32
+ "12ggygcfhny5sqq18zn6qyyqbh9314niywjagv9nclwxfa0i9pvr"))))
+ (native-inputs `(("bash" ,bash)))
+ (build-system emacs-build-system)
+ (home-page "https://github.com/szermatt/emacs-bash-completion")
+ (synopsis "BASH completion for the shell buffer")
+ (description
+ "@code{bash-completion} defines dynamic completion hooks for shell-mode
+and shell-command prompts that are based on bash completion.
+")
+ (license license:gpl3+)))
--
Jan Nieuwenhuizen <janneke <at> gnu.org> | GNU LilyPond http://lilypond.org
Freelance IT http://JoyofSource.com | Avatar® http://AvatarAcademy.com
Information forwarded
to
guix-patches <at> gnu.org
:
bug#28327
; Package
guix-patches
.
(Sat, 02 Sep 2017 09:16:01 GMT)
Full text and
rfc822 format available.
Message #8 received at 28327 <at> debbugs.gnu.org (full text, mbox):
Jan Nieuwenhuizen writes:
> ---
> gnu/packages/emacs.scm | 25 +++++++++++++++++++++++++
> 1 file changed, 25 insertions(+)
>
> diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm
> index 612126eb3..f6165ba54 100644
> --- a/gnu/packages/emacs.scm
> +++ b/gnu/packages/emacs.scm
> @@ -59,6 +59,7 @@
> #:use-module (guix build-system trivial)
> #:use-module (gnu packages)
> #:use-module (gnu packages audio)
> + #:use-module (gnu packages bash)
> #:use-module (gnu packages code)
> #:use-module (gnu packages guile)
> #:use-module (gnu packages gtk)
> @@ -5444,3 +5445,27 @@ key. Optionally, a mouse pop-up can be added by binding
> version of Idris, and some features may rely on the latest Git version of
> Idris.")
> (license license:gpl3+)))
> +
> +(define-public emacs-batch-completion
Oops, I really meant to type `emacs-bash-completion' here.
> + (package
> + (name "emacs-bash-completion")
> + (version "20170901.1445")
> + (source
> + (origin
> + (method url-fetch)
> + (uri (string-append
> + "http://melpa.org/packages/bash-completion-"
> + version
> + ".tar"))
> + (sha256
> + (base32
> + "12ggygcfhny5sqq18zn6qyyqbh9314niywjagv9nclwxfa0i9pvr"))))
> + (native-inputs `(("bash" ,bash)))
> + (build-system emacs-build-system)
> + (home-page "https://github.com/szermatt/emacs-bash-completion")
> + (synopsis "BASH completion for the shell buffer")
> + (description
> + "@code{bash-completion} defines dynamic completion hooks for shell-mode
> +and shell-command prompts that are based on bash completion.
> +")
> + (license license:gpl3+)))
--
Jan Nieuwenhuizen <janneke <at> gnu.org> | GNU LilyPond http://lilypond.org
Freelance IT http://JoyofSource.com | Avatar® http://AvatarAcademy.com
Information forwarded
to
guix-patches <at> gnu.org
:
bug#28327
; Package
guix-patches
.
(Mon, 04 Sep 2017 18:49:02 GMT)
Full text and
rfc822 format available.
Message #11 received at 28327 <at> debbugs.gnu.org (full text, mbox):
Jan Nieuwenhuizen (2017-09-02 11:11 +0200) wrote:
> ---
> gnu/packages/emacs.scm | 25 +++++++++++++++++++++++++
> 1 file changed, 25 insertions(+)
>
> diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm
> index 612126eb3..f6165ba54 100644
> --- a/gnu/packages/emacs.scm
> +++ b/gnu/packages/emacs.scm
> @@ -59,6 +59,7 @@
> #:use-module (guix build-system trivial)
> #:use-module (gnu packages)
> #:use-module (gnu packages audio)
> + #:use-module (gnu packages bash)
> #:use-module (gnu packages code)
> #:use-module (gnu packages guile)
> #:use-module (gnu packages gtk)
> @@ -5444,3 +5445,27 @@ key. Optionally, a mouse pop-up can be added by binding
> version of Idris, and some features may rely on the latest Git version of
> Idris.")
> (license license:gpl3+)))
> +
> +(define-public emacs-batch-completion
> + (package
> + (name "emacs-bash-completion")
> + (version "20170901.1445")
> + (source
> + (origin
> + (method url-fetch)
> + (uri (string-append
> + "http://melpa.org/packages/bash-completion-"
Please use the source directly from the upstream, i.e.:
https://github.com/szermatt/emacs-bash-completion/archive/v2.0.0.tar.gz
There is a problem with MELPA: when there will be a new commit in the
repo, the new melpa tarball will be generated and the previous one
("20170901.1445") will be *removed*, so this package will lose its
source.
> + version
> + ".tar"))
I wouldn't leave ‘version’ and ‘".tar"’ on separate lines, but it's a
matter of taste :-)
> + (sha256
> + (base32
> + "12ggygcfhny5sqq18zn6qyyqbh9314niywjagv9nclwxfa0i9pvr"))))
> + (native-inputs `(("bash" ,bash)))
You probably meant to make this package call this "bash" (btw it should
be 'input', not 'native-input') from store, but this is not enough. You
also need to patch 'bash-completion-prog' variable using
'emacs-substitute-variables' procedure (see (gnu packages emacs) module
for the examples).
> + (build-system emacs-build-system)
> + (home-page "https://github.com/szermatt/emacs-bash-completion")
> + (synopsis "BASH completion for the shell buffer")
> + (description
> + "@code{bash-completion} defines dynamic completion hooks for shell-mode
> +and shell-command prompts that are based on bash completion.
> +")
Please put this quote and parenthesis to the previous line.
> + (license license:gpl3+)))
I see GPL 2 or later in "bash-completion.el".
--
Alex
Information forwarded
to
guix-patches <at> gnu.org
:
bug#28327
; Package
guix-patches
.
(Wed, 06 Sep 2017 17:54:02 GMT)
Full text and
rfc822 format available.
Message #14 received at 28327 <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
Alex Kost writes:
> Jan Nieuwenhuizen (2017-09-02 11:11 +0200) wrote:
>
>> ---
>> gnu/packages/emacs.scm | 25 +++++++++++++++++++++++++
>> 1 file changed, 25 insertions(+)
> Please use the source directly from the upstream, i.e.:
>
> https://github.com/szermatt/emacs-bash-completion/archive/v2.0.0.tar.gz
Ok!
> There is a problem with MELPA: when there will be a new commit in the
> repo, the new melpa tarball will be generated and the previous one
> ("20170901.1445") will be *removed*, so this package will lose its
> source.
Ugh...how reproducible! I didn't know (or investigate...), thanks for
the explanation.
>> + version
>> + ".tar"))
>
> I wouldn't leave ‘version’ and ‘".tar"’ on separate lines, but it's a
> matter of taste :-)
I like your suggestion.
>> + (sha256
>> + (base32
>> + "12ggygcfhny5sqq18zn6qyyqbh9314niywjagv9nclwxfa0i9pvr"))))
>> + (native-inputs `(("bash" ,bash)))
>
> You probably meant to make this package call this "bash" (btw it should
> be 'input', not 'native-input') from store, but this is not enough.
Indeed. It took me quite a while of debugging until I finally stumbled
upon bash-minimal. Google had a very hard time telling me how complete
or compgen could not exist.
> You also need to patch 'bash-completion-prog' variable using
> 'emacs-substitute-variables' procedure (see (gnu packages emacs)
> module for the examples).
I have added something here and built package works and looks okay...
Because adding bash to (native-)inputs already made that
'emacs-substitute-variables' is set to bash instead of bash-minimal, I
don't really know how to test it.
>> + (build-system emacs-build-system)
>> + (home-page "https://github.com/szermatt/emacs-bash-completion")
>> + (synopsis "BASH completion for the shell buffer")
>> + (description
>> + "@code{bash-completion} defines dynamic completion hooks for shell-mode
>> +and shell-command prompts that are based on bash completion.
>> +")
>
> Please put this quote and parenthesis to the previous line.
Ok.
>> + (license license:gpl3+)))
>
> I see GPL 2 or later in "bash-completion.el".
I used guix import elpa --archive=melpa and didn't check. It seems we
cannot rely on that!
New version attached, still 13 of the 30 lines were unchanged,
wow...thanks for all your helpful remarks!
Greetings,
janneke
[0001-gnu-Add-emacs-bash-completion.patch (text/x-patch, inline)]
From 14649caae21669adcc495b109b8d328f5b71c2e9 Mon Sep 17 00:00:00 2001
From: Jan Nieuwenhuizen <janneke <at> gnu.org>
Date: Sat, 2 Sep 2017 10:54:14 +0200
Subject: [PATCH] gnu: Add emacs-bash-completion.
* gnu/packages/emacs.scm (emacs-bash-completion): New variable.
---
gnu/packages/emacs.scm | 33 +++++++++++++++++++++++++++++++++
1 file changed, 33 insertions(+)
diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm
index 9c0f9bc89..a4157a3db 100644
--- a/gnu/packages/emacs.scm
+++ b/gnu/packages/emacs.scm
@@ -59,6 +59,7 @@
#:use-module (guix build-system trivial)
#:use-module (gnu packages)
#:use-module (gnu packages audio)
+ #:use-module (gnu packages bash)
#:use-module (gnu packages code)
#:use-module (gnu packages guile)
#:use-module (gnu packages gtk)
@@ -5575,3 +5576,35 @@ It is meant to quickly generate linear ranges, e.g. 5, 6, 7, 8. Some elisp
proficiency is an advantage, since you can transform your numeric range with
an elisp expression.")
(license license:gpl3+)))
+
+(define-public emacs-bash-completion
+ (package
+ (name "emacs-bash-completion")
+ (version "2.0.0")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (string-append
+ "https://github.com/szermatt/emacs-bash-completion/archive/v"
+ version ".tar.gz"))
+ (file-name (string-append name "-" version ".tar.gz"))
+ (sha256
+ (base32
+ "0mkci4a1fy8z4cmry8mx5vsx4f16a8r454slnh7lqzidnhfi63hj"))))
+ (inputs `(("bash" ,bash)))
+ (build-system emacs-build-system)
+ (arguments
+ `(#:phases
+ (modify-phases %standard-phases
+ (add-before 'install 'configure
+ (lambda* (#:key inputs #:allow-other-keys)
+ (let ((bash (assoc-ref inputs "bash")))
+ (emacs-substitute-variables "bash-completion.el"
+ ("bash-completion-prog" (string-append bash "/bin/bash"))))
+ #t)))))
+ (home-page "https://github.com/szermatt/emacs-bash-completion")
+ (synopsis "BASH completion for the shell buffer")
+ (description
+ "@code{bash-completion} defines dynamic completion hooks for shell-mode
+and shell-command prompts that are based on bash completion.")
+ (license license:gpl2+)))
--
Jan Nieuwenhuizen <janneke <at> gnu.org> | GNU LilyPond http://lilypond.org
Freelance IT http://JoyofSource.com | Avatar® http://AvatarAcademy.com
[Message part 3 (text/plain, inline)]
--
Jan Nieuwenhuizen <janneke <at> gnu.org> | GNU LilyPond http://lilypond.org
Freelance IT http://JoyofSource.com | Avatar® http://AvatarAcademy.com
Information forwarded
to
guix-patches <at> gnu.org
:
bug#28327
; Package
guix-patches
.
(Sat, 09 Sep 2017 19:45:02 GMT)
Full text and
rfc822 format available.
Message #17 received at 28327 <at> debbugs.gnu.org (full text, mbox):
Jan Nieuwenhuizen (2017-09-06 19:52 +0200) wrote:
> Alex Kost writes:
[...]
>> You also need to patch 'bash-completion-prog' variable using
>> 'emacs-substitute-variables' procedure (see (gnu packages emacs)
>> module for the examples).
>
> I have added something here and built package works and looks okay...
Now it looks OK for me as well :-)
> Because adding bash to (native-)inputs already made that
> 'emacs-substitute-variables' is set to bash instead of bash-minimal, I
> don't really know how to test it.
I see that with your patch, 'bash-completion-prog' has the value
"/gnu/store/...-bash-4.4.12/bin/bash", so it is definitely 'bash'
('bash-minimal' has "/gnu/store/...-bash-minimal-4.4.12/bin/bash" name).
[...]
>>> + (license license:gpl3+)))
>>
>> I see GPL 2 or later in "bash-completion.el".
>
> I used guix import elpa --archive=melpa and didn't check. It seems we
> cannot rely on that!
We definitely shouldn't rely on it, as the importer always puts 'gpl3+':
http://git.savannah.gnu.org/cgit/guix.git/tree/guix/import/elpa.scm#n234
> New version attached, still 13 of the 30 lines were unchanged,
> wow...thanks for all your helpful remarks!
The patch looks good for me, thank you!
--
Alex
Reply sent
to
Jan Nieuwenhuizen <janneke <at> gnu.org>
:
You have taken responsibility.
(Sun, 10 Sep 2017 20:46:01 GMT)
Full text and
rfc822 format available.
Notification sent
to
Jan Nieuwenhuizen <janneke <at> gnu.org>
:
bug acknowledged by developer.
(Sun, 10 Sep 2017 20:46:01 GMT)
Full text and
rfc822 format available.
Message #22 received at 28327-done <at> debbugs.gnu.org (full text, mbox):
Alex Kost writes:
>> I have added something here and built package works and looks okay...
>
> Now it looks OK for me as well :-)
Good!
> I see that with your patch, 'bash-completion-prog' has the value
> "/gnu/store/...-bash-4.4.12/bin/bash", so it is definitely 'bash'
> ('bash-minimal' has "/gnu/store/...-bash-minimal-4.4.12/bin/bash" name).
Also good, thanks for checking.
>> I used guix import elpa --archive=melpa and didn't check. It seems we
>> cannot rely on that!
>
> We definitely shouldn't rely on it, as the importer always puts 'gpl3+':
>
> http://git.savannah.gnu.org/cgit/guix.git/tree/guix/import/elpa.scm#n234
Great!
> The patch looks good for me, thank you!
Pushed to master as 4aafce22ab74007c69aecc474816d83e64d22646
janneke
--
Jan Nieuwenhuizen <janneke <at> gnu.org> | GNU LilyPond http://lilypond.org
Freelance IT http://JoyofSource.com | Avatar® http://AvatarAcademy.com
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Mon, 09 Oct 2017 11:24:04 GMT)
Full text and
rfc822 format available.
This bug report was last modified 7 years and 257 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.