* [PATCH ?] gnu: Add dash.
@ 2016-07-28 2:03 Tobias Geerinckx-Rice
2016-07-28 12:44 ` Ludovic Courtès
0 siblings, 1 reply; 8+ messages in thread
From: Tobias Geerinckx-Rice @ 2016-07-28 2:03 UTC (permalink / raw)
To: guix-devel
* gnu/packages/dash.shm: New file.
---
Guix!
IMO this belongs in a (new) shell.scm with fish, tcsh and zsh.
Maybe bash, too. On the other hand:
Certain shells might have an 'ecosystem' of 'packages', such as
bash-completion in bash.scm, that might justify leaving them in
their own file. I'm thinking specifically of zsh here.
I'd suggest merging them all and splitting out if and when needed,
but prefer to ask the wisdom of the list before doing that tedious
deed.
Kind regards,
T G-R
gnu/packages/dash.scm | 60 +++++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 60 insertions(+)
create mode 100644 gnu/packages/dash.scm
diff --git a/gnu/packages/dash.scm b/gnu/packages/dash.scm
new file mode 100644
index 0000000..017e81c
--- /dev/null
+++ b/gnu/packages/dash.scm
@@ -0,0 +1,60 @@
+;;; GNU Guix --- Functional package management for GNU
+;;; Copyright © 2016 Tobias Geerinckx-Rice <me@tobias.gr>
+;;;
+;;; This file is part of GNU Guix.
+;;;
+;;; GNU Guix is free software; you can redistribute it and/or modify it
+;;; under the terms of the GNU General Public License as published by
+;;; the Free Software Foundation; either version 3 of the License, or (at
+;;; your option) any later version.
+;;;
+;;; GNU Guix is distributed in the hope that it will be useful, but
+;;; WITHOUT ANY WARRANTY; without even the implied warranty of
+;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;;; GNU General Public License for more details.
+;;;
+;;; You should have received a copy of the GNU General Public License
+;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
+
+(define-module (gnu packages dash)
+ #:use-module (guix licenses)
+ #:use-module (guix packages)
+ #:use-module (guix download)
+ #:use-module (guix build-system gnu)
+ #:use-module (gnu packages libedit))
+
+(define-public dash
+ (package
+ (name "dash")
+ (version "0.5.9")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (string-append "http://gondor.apana.org.au/~herbert/dash/files/"
+ name "-" version ".tar.gz"))
+ (sha256
+ (base32
+ "17328wd9n5krr5wd37smrk0y7fdf8aa3hmhm02br5mqpq0a3nycj"))
+ (modules '((guix build utils)))
+ (snippet
+ '(begin
+ ;; The man page hails from BSD, where (d)ash is the default shell.
+ ;; This isn't the case on Guix or indeed most other GNU systems.
+ (substitute* "src/dash.1"
+ (("the standard command interpreter for the system")
+ "a command interpreter based on the original Bourne shell"))
+ #t))))
+ (build-system gnu-build-system)
+ (inputs
+ `(("libedit" ,libedit)))
+ (arguments
+ `(#:configure-flags '("--with-libedit")))
+ (home-page "http://gondor.apana.org.au/~herbert/dash")
+ (synopsis "POSIX-compliant shell optimised for size")
+ (description
+ "dash is a POSIX-compliant @command{/bin/sh} implementation that aims to be
+as small as possible, often without sacrificing speed. It is significantly
+faster than the GNU Bourne-Again Shell (@command{bash}) at most tasks. dash is
+a direct descendant of NetBSD's Almquist Shell (@command{ash}).")
+ (license (list bsd-3
+ gpl2+)))) ; mksignames.c
--
2.9.2
^ permalink raw reply related [flat|nested] 8+ messages in thread
* Re: [PATCH ?] gnu: Add dash.
2016-07-28 2:03 [PATCH ?] gnu: Add dash Tobias Geerinckx-Rice
@ 2016-07-28 12:44 ` Ludovic Courtès
2016-07-29 14:44 ` ng0
0 siblings, 1 reply; 8+ messages in thread
From: Ludovic Courtès @ 2016-07-28 12:44 UTC (permalink / raw)
To: Tobias Geerinckx-Rice; +Cc: guix-devel
Hi!
Tobias Geerinckx-Rice <me@tobias.gr> skribis:
> * gnu/packages/dash.shm: New file.
> ---
>
> Guix!
>
> IMO this belongs in a (new) shell.scm with fish, tcsh and zsh.
> Maybe bash, too. On the other hand:
>
> Certain shells might have an 'ecosystem' of 'packages', such as
> bash-completion in bash.scm, that might justify leaving them in
> their own file. I'm thinking specifically of zsh here.
>
> I'd suggest merging them all and splitting out if and when needed,
> but prefer to ask the wisdom of the list before doing that tedious
> deed.
I would keep Bash separate, but I agree it’s a good idea to merge the
other ones in one module.
If you want, you could do that and then add Dash to that file?
[...]
> + (home-page "http://gondor.apana.org.au/~herbert/dash")
> + (synopsis "POSIX-compliant shell optimised for size")
> + (description
> + "dash is a POSIX-compliant @command{/bin/sh} implementation that aims to be
> +as small as possible, often without sacrificing speed. It is significantly
> +faster than the GNU Bourne-Again Shell (@command{bash}) at most tasks. dash is
> +a direct descendant of NetBSD's Almquist Shell (@command{ash}).")
> + (license (list bsd-3
> + gpl2+)))) ; mksignames.c
I’d tend to remove “significantly” :-), but otherwise LGTM, thanks!
Ludo’.
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH ?] gnu: Add dash.
2016-07-28 12:44 ` Ludovic Courtès
@ 2016-07-29 14:44 ` ng0
2016-07-29 15:51 ` Leo Famulari
0 siblings, 1 reply; 8+ messages in thread
From: ng0 @ 2016-07-29 14:44 UTC (permalink / raw)
To: Ludovic Courtès, Tobias Geerinckx-Rice; +Cc: guix-devel
Ludovic Courtès <ludo@gnu.org> writes:
> Hi!
>
> Tobias Geerinckx-Rice <me@tobias.gr> skribis:
>
>> * gnu/packages/dash.shm: New file.
>> ---
>>
>> Guix!
>>
>> IMO this belongs in a (new) shell.scm with fish, tcsh and zsh.
>> Maybe bash, too. On the other hand:
>>
>> Certain shells might have an 'ecosystem' of 'packages', such as
>> bash-completion in bash.scm, that might justify leaving them in
>> their own file. I'm thinking specifically of zsh here.
>>
>> I'd suggest merging them all and splitting out if and when needed,
>> but prefer to ask the wisdom of the list before doing that tedious
>> deed.
>
> I would keep Bash separate, but I agree it’s a good idea to merge the
> other ones in one module.
>
> If you want, you could do that and then add Dash to that file?
>
> [...]
>
>> + (home-page "http://gondor.apana.org.au/~herbert/dash")
>> + (synopsis "POSIX-compliant shell optimised for size")
>> + (description
>> + "dash is a POSIX-compliant @command{/bin/sh} implementation that aims to be
>> +as small as possible, often without sacrificing speed. It is significantly
>> +faster than the GNU Bourne-Again Shell (@command{bash}) at most tasks. dash is
>> +a direct descendant of NetBSD's Almquist Shell (@command{ash}).")
>> + (license (list bsd-3
>> + gpl2+)))) ; mksignames.c
>
> I’d tend to remove “significantly” :-), but otherwise LGTM, thanks!
I second this. Significantly faster is subjectiv as long as we do not
provide some side by side benchmark results etc.
> Ludo’.
>
--
♥Ⓐ ng0
Current Keys: https://we.make.ritual.n0.is/ng0.txt
For non-prism friendly talk find me on http://www.psyced.org
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH ?] gnu: Add dash.
2016-07-29 14:44 ` ng0
@ 2016-07-29 15:51 ` Leo Famulari
2016-07-31 21:18 ` Tobias Geerinckx-Rice
0 siblings, 1 reply; 8+ messages in thread
From: Leo Famulari @ 2016-07-29 15:51 UTC (permalink / raw)
To: ng0; +Cc: guix-devel
On Fri, Jul 29, 2016 at 02:44:27PM +0000, ng0 wrote:
> I second this. Significantly faster is subjectiv as long as we do not
> provide some side by side benchmark results etc.
I'm not suggesting that we run the benchmarks or put 'significantly'
back in the description, but I would like to include some context.
This is the shell that Debian uses as the default non-interactive
"system" shell. They replaced Bash with dash in that context in order to
reduce the time spent on shell initialization for things like the boot
sequence.
Just an FYI.
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH ?] gnu: Add dash.
2016-07-29 15:51 ` Leo Famulari
@ 2016-07-31 21:18 ` Tobias Geerinckx-Rice
2016-07-31 21:58 ` Leo Famulari
` (2 more replies)
0 siblings, 3 replies; 8+ messages in thread
From: Tobias Geerinckx-Rice @ 2016-07-31 21:18 UTC (permalink / raw)
To: Leo Famulari, ng0; +Cc: guix-devel
Hullo all,
On Fri, Jul 29, 2016 at 02:44:27PM +0000, ng0 wrote:
> Ludovic Courtès <ludo@gnu.org> writes:
>> I’d tend to remove “significantly” , but otherwise LGTM, thanks!
> I second this. Significantly faster is subjectiv as long as we do not
> provide some side by side benchmark results etc.
Let's not give Phoronix any ideas.
While I am convinced that ‘significantly faster’ is an objective fact, I
agree that such claims smell so subjective that they don't belong in
Guix. I just copied that bit from upstream, to be honest. Dropped.
On 29/07/2016 17:51, Leo Famulari wrote:
> I'm not suggesting that we run the benchmarks or put 'significantly'
> back in the description, but I would like to include some context.
>
> This is the shell that Debian uses as the default non-interactive
> "system" shell. They replaced Bash with dash in that context in order to
> reduce the time spent on shell initialization for things like the boot
> sequence.
Indeed; thanks for adding that. dash is horrible for interactive use,
but fast at running shell[1] scripts. If anyone thinks that might be
relevant in the description, let me know.
Otherwise, I'll push it soon with the suggested changes.
Kind regards,
T G-R
[1]: It's also a trivial way to catch 98% of bash-specific code.
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH ?] gnu: Add dash.
2016-07-31 21:18 ` Tobias Geerinckx-Rice
@ 2016-07-31 21:58 ` Leo Famulari
2016-08-01 12:02 ` Ludovic Courtès
2016-08-03 3:04 ` [PATCH] gnu: Add dash to shells.scm Tobias Geerinckx-Rice
2 siblings, 0 replies; 8+ messages in thread
From: Leo Famulari @ 2016-07-31 21:58 UTC (permalink / raw)
To: Tobias Geerinckx-Rice; +Cc: guix-devel
On Sun, Jul 31, 2016 at 11:18:14PM +0200, Tobias Geerinckx-Rice wrote:
> Indeed; thanks for adding that. dash is horrible for interactive use,
> but fast at running shell[1] scripts. If anyone thinks that might be
> relevant in the description, let me know.
Nope, no suggestion from me :) I just wanted to provide some context.
> [1]: It's also a trivial way to catch 98% of bash-specific code.
Yup, it's how I like to test /bin/sh scripts.
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH ?] gnu: Add dash.
2016-07-31 21:18 ` Tobias Geerinckx-Rice
2016-07-31 21:58 ` Leo Famulari
@ 2016-08-01 12:02 ` Ludovic Courtès
2016-08-03 3:04 ` [PATCH] gnu: Add dash to shells.scm Tobias Geerinckx-Rice
2 siblings, 0 replies; 8+ messages in thread
From: Ludovic Courtès @ 2016-08-01 12:02 UTC (permalink / raw)
To: Tobias Geerinckx-Rice; +Cc: guix-devel
Tobias Geerinckx-Rice <me@tobias.gr> skribis:
> Otherwise, I'll push it soon with the suggested changes.
Fine with me!
Thanks,
Ludo’.
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [PATCH] gnu: Add dash to shells.scm.
2016-07-31 21:18 ` Tobias Geerinckx-Rice
2016-07-31 21:58 ` Leo Famulari
2016-08-01 12:02 ` Ludovic Courtès
@ 2016-08-03 3:04 ` Tobias Geerinckx-Rice
2 siblings, 0 replies; 8+ messages in thread
From: Tobias Geerinckx-Rice @ 2016-08-03 3:04 UTC (permalink / raw)
To: guix-devel
On 31/07/16 23:18, Tobias Geerinckx-Rice wrote:
> I'll push it soon with the suggested changes.
Done — a bit more verbosely than intended because typing ‘origin’
instead of ‘upstream’ is apparently the hardest thing ever — in c356339
et al.
Kind regards,
T G-R
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2016-08-03 3:04 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-07-28 2:03 [PATCH ?] gnu: Add dash Tobias Geerinckx-Rice
2016-07-28 12:44 ` Ludovic Courtès
2016-07-29 14:44 ` ng0
2016-07-29 15:51 ` Leo Famulari
2016-07-31 21:18 ` Tobias Geerinckx-Rice
2016-07-31 21:58 ` Leo Famulari
2016-08-01 12:02 ` Ludovic Courtès
2016-08-03 3:04 ` [PATCH] gnu: Add dash to shells.scm Tobias Geerinckx-Rice
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).