Rename & upgrade oil-shell

  • Done
  • quality assurance status badge
Details
3 participants
  • Leo Famulari
  • Tobias Geerinckx-Rice
  • Ryan Prior
Owner
unassigned
Submitted by
Ryan Prior
Severity
normal
R
R
Ryan Prior wrote on 1 May 2020 22:01
(name . guix-patches@gnu.org)(address . guix-patches@gnu.org)
k3WMYYEx_MdUokPGxBg54cpM2QMuACaeKoRbRaxGox-XI3TW-PQx-WWVOY1H6gmv8oHs93NZ6VgMhQ-OkNZna-xcsSTB00xIICsrl1sX5Og=@protonmail.com
This patch renames oil-shell to oil, at the request of upstream authors.
Attachment: file
From 246c5f03f2d34a2a78e095bdfb0dd82de905eb0a Mon Sep 17 00:00:00 2001
From: Ryan Prior <rprior@protonmail.com>
Date: Fri, 1 May 2020 14:47:20 -0500
Subject: [PATCH] gnu: oil-shell: Rename to "oil" and add a deprecated alias

---
gnu/packages/shells.scm | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)

Toggle diff (19 lines)
diff --git a/gnu/packages/shells.scm b/gnu/packages/shells.scm
index c71e6399ea..08a475dfe1 100644
--- a/gnu/packages/shells.scm
+++ b/gnu/packages/shells.scm
@@ -749,8 +749,11 @@ Shell (pdksh).")
isc)))) ; strlcpy.c
(define-public oil-shell
+ (deprecated-package "oil-shell" oil))
+
+(define-public oil
(package
- (name "oil-shell")
+ (name "oil")
(version "0.7.0")
(source (origin
(method url-fetch)
--
2.17.1
R
R
Ryan Prior wrote on 1 May 2020 23:01
Upgrade Oil to 0.8.pre4
(name . 41010@debbugs.gnu.org)(address . 41010@debbugs.gnu.org)
h2J1HZL5TX-LD7iEonk5V7VW9SayB4-irRVMFeJgPnZUtokvrqPKg_5kyLqybb8UrlaW10p1-UOsek5Z8yV_qoZIPyOI4PBDQIZEFPH6--g=@protonmail.com
This patch upgrades the oil package. As noted in the package description, upstream considers this to be a stable release & the best available version of oil despite the "pre" tag.
Attachment: file
From 4b9726a57da890f36337fec045248812933d63ec Mon Sep 17 00:00:00 2001
From: Ryan Prior <rprior@protonmail.com>
Date: Fri, 1 May 2020 14:49:42 -0500
Subject: [PATCH] gnu: oil: Update to 0.8.pre4

---
gnu/packages/shells.scm | 66 ++++++++++++++++++++---------------------
1 file changed, 33 insertions(+), 33 deletions(-)

Toggle diff (95 lines)
diff --git a/gnu/packages/shells.scm b/gnu/packages/shells.scm
index 08a475dfe1..324bdf513d 100644
--- a/gnu/packages/shells.scm
+++ b/gnu/packages/shells.scm
@@ -13,6 +13,7 @@
;;; Copyright © 2019 Timothy Sample <samplet@ngyro.com>
;;; Copyright © 2019, 2020 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
;;; Copyright © 2020 Brice Waegeneire <brice@waegenei.re>
+;;; Copyright © 2020 Ryan Prior <rprior@protonmail.com>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -754,48 +755,47 @@ Shell (pdksh).")
(define-public oil
(package
(name "oil")
- (version "0.7.0")
- (source (origin
- (method url-fetch)
- (uri (string-append "https://www.oilshell.org/download/oil-"
- version ".tar.xz"))
- (sha256
- (base32
- "12c9s462879adb6mwd3fqafk0dnqsm16s18rhym6cmzfzy8v8zm3"))))
+ (version "0.8.pre4") ; "Despite the pre4 version qualifier, this is by far
+ ; the best Oil release ever… I may change the version
+ ; numbering scheme in the near future to reflect this."
+ ; - upstream on whether to ship pre4 in Guix
+ (source
+ (origin
+ (method url-fetch)
+ (uri (string-append "https://www.oilshell.org/download/oil-"
+ version ".tar.gz"))
+ (sha256
+ (base32
+ "0m2p8p5hi2r14xx9pphsa0ar56kqsa33gr2w2blc3jx07aqhjpzy"))))
(build-system gnu-build-system)
(arguments
- '(#:tests? #f ; the tests are not distributed in the tarballs
- #:strip-binaries? #f ; the binaries cannot be stripped
+ `(#:strip-binaries? #f ; Strip breaks the binary.
#:phases
(modify-phases %standard-phases
- (add-after 'unpack 'patch-compiler-invocation
- (lambda _
- (substitute* "configure"
- ((" cc ") " gcc "))
- #t))
(replace 'configure
(lambda* (#:key outputs #:allow-other-keys)
+ (setenv "CC" "gcc")
+ (substitute* "configure"
+ ((" cc ") " gcc "))
(let ((out (assoc-ref outputs "out")))
- (setenv "CC" "gcc")
- ;; The configure script doesn't recognize CONFIG_SHELL.
- (setenv "CONFIG_SHELL" (which "sh"))
- (invoke "./configure" (string-append "--prefix=" out)
- "--with-readline"))))
- (add-before 'install 'make-destination
+ (invoke
+ "./configure"
+ (string-append "--prefix=" out)
+ "--with-readline"))))
+ (replace 'check ; The tests are not distributed in the tarballs but
+ ; upstream recommends running this smoke test.
(lambda _
- ;; The build scripts don't create the destination directory.
- (mkdir-p (string-append (assoc-ref %outputs "out") "/bin")))))))
- (inputs
+ (let* ((oil "_bin/oil.ovm"))
+ (invoke/quiet oil "osh" "-c" "echo hi")
+ (invoke/quiet oil "osh" "-n" "configure")))))))
+ (native-inputs
`(("readline" ,readline)))
- (synopsis "Bash-compatible Unix shell")
- (description "Oil is a Unix / POSIX shell, compatible with Bash. It
-implements the Oil language, which is a new shell language to which Bash can be
-automatically translated. The Oil language is a superset of Bash. It also
-implements the OSH language, a statically-parseable language based on Bash as it
-is commonly written.")
- (home-page "https://www.oilshell.org/")
- (license (list psfl ; The Oil sources include a patched Python 2 source tree
- asl2.0))))
+ (home-page "https://www.oilshell.org")
+ (synopsis "A Unix shell")
+ (description "Oil is a Unix shell and programming language. It's our upgrade
+path from Bash.")
+ (license (list license:psfl ; Tarball vendors python2.7
+ license:asl2.0))))
(define-public gash
(package
--
2.17.1
T
T
Tobias Geerinckx-Rice wrote on 2 May 2020 01:23
(name . 41010@debbugs.gnu.org)(address . 41010@debbugs.gnu.org)
87sggjfdef.fsf@nckx
Ryan,

Toggle quote (4 lines)
> This patch upgrades the oil package. As noted in the package
> description, upstream considers this to be a stable release &
> the best available version of oil despite the "pre" tag.

Thanks!

I agree with the name change, although I'm unaware of why
‘oil-shell’ was originally chosen.

However, please do build and test patches before submitting them.
These were broken in 2 places: adding the unused ‘license:’ prefix
breaks evaluation, as does referring to a variable (‘oil’ in
deprecated-package) before it's defined.

Toggle quote (2 lines)
> Subject: [PATCH] gnu: oil: Update to 0.8.pre4

Add a full stop after commit summaries, and a ‘change log’ entry
as commit body:

* gnu/packages/shells.scm (oil): Update to 0.8.pre4.

Toggle quote (9 lines)
> + (version "0.8.pre4") ; "Despite the pre4 version qualifier,
> this is by far
> + ; the best Oil release ever… I may
> change the version
> + ; numbering scheme in the near future
> to reflect this."
> + ; - upstream on whether to ship pre4
> in Guix

;; "Despite the pre4 version qualifier, this is by far
;; the best Oil release ever… I may change the version
;; numbering scheme in the near future to reflect this."
;; - upstream on whether to ship pre4 in Guix
(version "0.8.pre4")

Format long and/or multi-line comments like so:

OTOH a one-line link to that thread, if one exists, would be
preferable.

Toggle quote (11 lines)
> + (source
> + (origin
> + (method url-fetch)
> + (uri (string-append
> "https://www.oilshell.org/download/oil-"
> + version ".tar.gz"))
> + (sha256
> + (base32
> +
> "0m2p8p5hi2r14xx9pphsa0ar56kqsa33gr2w2blc3jx07aqhjpzy"))))

If you're going to re-indent like this, the hash fits beside
(base32 ….

Toggle quote (3 lines)
> - #:strip-binaries? #f ; the binaries cannot be stripped
> + `(#:strip-binaries? #f ; Strip breaks the binary.

I like your comment better but the original formatting (lowercase,
no full stop) was fine.

Toggle quote (4 lines)
> + (setenv "CC" "gcc")
> (let ((out (assoc-ref outputs "out")))
> - (setenv "CC" "gcc")

(let ((out (assoc-ref outputs "out")))
(do-something "foo")
(do-something out))

It's canonical style in Guix (not sure about wider Schemeland) to
‘bind early’:

(do-something "foo")
(let ((out (assoc-ref outputs "out")))
(do-something out))

While you'll find a fair share of

it's much less common, possibly frowned upon, and idly rearranging
existing code is right out.

Toggle quote (3 lines)
> + (substitute* "configure"
> + ((" cc ") " gcc "))

(substitute* "configure"
((" cc ") " $CC "))

Toggle quote (3 lines)
> + (invoke
> + "./configure"

More line nitpicking: keep these on one line & indent the other
arguments accordingly.

Toggle quote (5 lines)
> + (replace 'check ; The tests are not distributed in the
> tarballs but
> + ; upstream recommends running this
> smoke test.

Same as above:

(replace 'check
;; The tests are not distributed in the tarballs but upstream
;; recommends running this smoke test.

Where do they recommend this? It's nice to have a link in case
the recommendation changes.

Toggle quote (2 lines)
> + (native-inputs

Nak. ‘Native’ means ‘when cross compiling, don't bother building
this for the target architecture, it will only ever run on the
host’…

Toggle quote (2 lines)
> `(("readline" ,readline)))

…as ‘guix gc --references oil’ (and readline's general nature)
tell us, that's not the case here: Oil links to it at run time, so
it must not be native.

Toggle quote (11 lines)
> - (synopsis "Bash-compatible Unix shell")
> - (description "Oil is a Unix / POSIX shell, compatible with
> Bash. It
> -implements the Oil language, which is a new shell language to
> which Bash can be
> -automatically translated. The Oil language is a superset of
> Bash. It also
> -implements the OSH language, a statically-parseable language
> based on Bash as it
> -is commonly written.")

[…]

Toggle quote (5 lines)
> + (synopsis "A Unix shell")
> + (description "Oil is a Unix shell and programming
> language. It's our upgrade
> +path from Bash.")

Both the original synopsis and description are much better. If
certain things are no longer accurate they can be adjusted but
this is just upstream's marketing pitch.

Toggle quote (2 lines)
> + (license (list license:psfl ; Tarball vendors python2.7

Hmm, this doesn't parse as English (it's missing a verb). I'd
guess typo… but for what? Are upstream the ‘tarball vendors’
here? What was wrong with the original comment?

If upstream still bundles Python (and it would seem so), that's
important information that shouldn't be removed.

Phew. ‘I'll just review this trivial bump before bed-time.’ This
patch changes lots of things for one small package. I hope you
don't mind lots of comments :-)

Kind regards,

T G-R
-----BEGIN PGP SIGNATURE-----

iHUEARYKAB0WIQT12iAyS4c9C3o4dnINsP+IT1VteQUCXqyvcwAKCRANsP+IT1Vt
eYFGAP9ZAvffgA9WEx8i+0O3uyD0nhUkDvJh8DJVOS9dfOXOXAEAwP0TqycO+xVi
RnvfMAzoag62FoCLM+CuLTXUUptMoAk=
=JQ1t
-----END PGP SIGNATURE-----

T
T
Tobias Geerinckx-Rice wrote on 2 May 2020 01:33
(name . Tobias Geerinckx-Rice via Guix-patches)(address . guix-patches@gnu.org)
87mu6rfcwp.fsf@nckx
of lines out of order

This bizarre formatting:

is not something I did.

Emacs tried to warn me about some weird encoding issues (which
were in turn related to the original patch encoding, e.g. © and …)
and I ignored it at my peril. The patch applied just fine.

Kind regards,

T G-R
-----BEGIN PGP SIGNATURE-----

iHUEARYKAB0WIQT12iAyS4c9C3o4dnINsP+IT1VteQUCXqyx5gAKCRANsP+IT1Vt
eRiXAQDmIsgGwdQT2sntMlhLirXL+DwXgT1VzFzQmAJz4BPEewEA2nF1OsE1T5Pk
hM/4rao54xUpM0hDbijRelzlhW4BigI=
=E6AI
-----END PGP SIGNATURE-----

R
R
Ryan Prior wrote on 2 May 2020 06:02
(name . Tobias Geerinckx-Rice)(address . me@tobias.gr)(name . 41010\@debbugs.gnu.org)(address . 41010@debbugs.gnu.org)
7j_T0Kf3tHwi7uYPSXZUYLjdVXe_LWrzbgE6XY7mdt-HZsxZQhTuCs8-H4kISkUui_q7IL1BrSnkCIksY62JtGWP-_gXsDC3MBnfusZzcOA=@protonmail.com
Tobias, thank you for the quick and thorough review! I've attached updated patches.

A little context on how this patch came to be might make some of my choices a little less mysterious: I didn't actually start with the original package definition, because I didn't realize oil was already packaged in Guix. (I searched for "osh", not "oil-shell")

So I wrote my own package, went to find where to put it in the guix source tree, found the existing package, and then kinda merged them together.



On Friday, May 1, 2020 11:23 PM, Tobias Geerinckx-Rice <me@tobias.gr> wrote:

Toggle quote (2 lines)
> However, please do build and test patches before submitting them.

Done! I test my packages mostly by running `guix build -f mypackage.scm` so I had to figure out how to build it in the context of the source tree.

Toggle quote (2 lines)
> Add a full stop after commit summaries, and a ‘change log’ entry as commit body:

Added.

Toggle quote (2 lines)
> OTOH a one-line link to that thread, if one exists, would be preferable.

Changed to a one-line link.

Toggle quote (2 lines)
> Where do they recommend this? It's nice to have a link in case the recommendation changes.

Added a link to the recommendation.


Toggle quote (2 lines)
> …as ‘guix gc --references oil’ (and readline's general nature) tell us, that's not the case here: Oil links to it at run time, so it must not be native.

I changed it to a normal input.

Toggle quote (2 lines)
> Both the original synopsis and description are much better. If certain things are no longer accurate they can be adjusted but this is just upstream's marketing pitch.

I did ask upstream what they'd want as a synopsis/description. I updated it to be more similar to the original but edited for accuracy.

Toggle quote (5 lines)
>
> > - (license (list license:psfl ; Tarball vendors python2.7
>
> Hmm, this doesn't parse as English (it's missing a verb). I'd guess typo… but for what? Are upstream the ‘tarball vendors’ here? What was wrong with the original comment?

In some software development circles, we do use "vendor" as a verb. Sorry for the confusion!

Toggle quote (5 lines)
>vendor (third-person singular simple present vendors, present participle vendoring, simple past and past participle vendored)
>
> (transitive, software development) To bundle third-party dependencies with the source code for one's own program.
>
> I distributed my application with a vendored copy of Perl so that it wouldn't use the system copies of Perl where it is installed.

In favor of readability I changed the verb to "includes."

Toggle quote (2 lines)
> Phew. ‘I'll just review this trivial bump before bed-time.’ This patch changes lots of things for one small package. I hope you don't mind lots of comments :-)

Thank you again, I appreciated all the comments!

Sincerely,
Ryan
From a7fb173a203d85430158b8748223e646d1d539c6 Mon Sep 17 00:00:00 2001
From: Ryan Prior <rprior@protonmail.com>
Date: Fri, 1 May 2020 14:49:42 -0500
Subject: [PATCH] gnu: oil: Update to 0.8.pre4

gnu/packages/shells.scm (oil): Update to 0.8.pre4.
---
gnu/packages/shells.scm | 56 ++++++++++++++++++++---------------------
1 file changed, 27 insertions(+), 29 deletions(-)

Toggle diff (88 lines)
diff --git a/gnu/packages/shells.scm b/gnu/packages/shells.scm
index 10f0ec817c..445eacae2c 100644
--- a/gnu/packages/shells.scm
+++ b/gnu/packages/shells.scm
@@ -13,6 +13,7 @@
;;; Copyright © 2019 Timothy Sample <samplet@ngyro.com>
;;; Copyright © 2019, 2020 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
;;; Copyright © 2020 Brice Waegeneire <brice@waegenei.re>
+;;; Copyright © 2020 Ryan Prior <rprior@protonmail.com>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -751,47 +752,44 @@ Shell (pdksh).")
(define-public oil
(package
(name "oil")
- (version "0.7.0")
- (source (origin
- (method url-fetch)
- (uri (string-append "https://www.oilshell.org/download/oil-"
- version ".tar.xz"))
- (sha256
- (base32
- "12c9s462879adb6mwd3fqafk0dnqsm16s18rhym6cmzfzy8v8zm3"))))
+ (version "0.8.pre4") ; https://www.oilshell.org/blog/2020/04/release-0.8.pre4.html#comment-on-version-numbering
+ (source
+ (origin
+ (method url-fetch)
+ (uri (string-append "https://www.oilshell.org/download/oil-"
+ version ".tar.gz"))
+ (sha256
+ (base32 "0m2p8p5hi2r14xx9pphsa0ar56kqsa33gr2w2blc3jx07aqhjpzy"))))
(build-system gnu-build-system)
(arguments
- '(#:tests? #f ; the tests are not distributed in the tarballs
- #:strip-binaries? #f ; the binaries cannot be stripped
+ `(#:strip-binaries? #f ; strip breaks the binary
#:phases
(modify-phases %standard-phases
- (add-after 'unpack 'patch-compiler-invocation
- (lambda _
- (substitute* "configure"
- ((" cc ") " gcc "))
- #t))
(replace 'configure
(lambda* (#:key outputs #:allow-other-keys)
(let ((out (assoc-ref outputs "out")))
(setenv "CC" "gcc")
- ;; The configure script doesn't recognize CONFIG_SHELL.
- (setenv "CONFIG_SHELL" (which "sh"))
- (invoke "./configure" (string-append "--prefix=" out)
+ (substitute* "configure"
+ ((" cc ") " gcc "))
+ (invoke "./configure"
+ (string-append "--prefix=" out)
"--with-readline"))))
- (add-before 'install 'make-destination
+ (replace 'check
+ ;; The tests are not distributed in the tarballs but upstream
+ ;; recommends running this smoke test.
+ ;; https://github.com/oilshell/oil/blob/release/0.8.pre4/INSTALL.txt#L38-L48
(lambda _
- ;; The build scripts don't create the destination directory.
- (mkdir-p (string-append (assoc-ref %outputs "out") "/bin")))))))
+ (let* ((oil "_bin/oil.ovm"))
+ (invoke/quiet oil "osh" "-c" "echo hi")
+ (invoke/quiet oil "osh" "-n" "configure")))))))
(inputs
`(("readline" ,readline)))
- (synopsis "Bash-compatible Unix shell")
- (description "Oil is a Unix / POSIX shell, compatible with Bash. It
-implements the Oil language, which is a new shell language to which Bash can be
-automatically translated. The Oil language is a superset of Bash. It also
-implements the OSH language, a statically-parseable language based on Bash as it
-is commonly written.")
- (home-page "https://www.oilshell.org/")
- (license (list psfl ; The Oil sources include a patched Python 2 source tree
+ (home-page "https://www.oilshell.org")
+ (synopsis "Programming language and Bash-compatible Unix shell")
+ (description "Oil is a programming language with automatic translation for
+Bash. It includes osh, a Unix/POSIX shell that runs unmodified Bash
+scripts.")
+ (license (list psfl ; tarball includes python2.7
asl2.0))))
(define-public oil-shell
--
2.17.1
From cb72dd3705eb51fa0a5a028443b01af95aff9ca1 Mon Sep 17 00:00:00 2001
From: Ryan Prior <rprior@protonmail.com>
Date: Fri, 1 May 2020 14:47:20 -0500
Subject: [PATCH] gnu: oil-shell: Rename to "oil" and add a deprecated alias

---
gnu/packages/shells.scm | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)

Toggle diff (28 lines)
diff --git a/gnu/packages/shells.scm b/gnu/packages/shells.scm
index c71e6399ea..10f0ec817c 100644
--- a/gnu/packages/shells.scm
+++ b/gnu/packages/shells.scm
@@ -748,9 +748,9 @@ Shell (pdksh).")
(license (list miros
isc)))) ; strlcpy.c
-(define-public oil-shell
+(define-public oil
(package
- (name "oil-shell")
+ (name "oil")
(version "0.7.0")
(source (origin
(method url-fetch)
@@ -794,6 +794,9 @@ is commonly written.")
(license (list psfl ; The Oil sources include a patched Python 2 source tree
asl2.0))))
+(define-public oil-shell
+ (deprecated-package "oil-shell" oil))
+
(define-public gash
(package
(name "gash")
--
2.17.1
L
L
Leo Famulari wrote on 2 May 2020 21:16
(name . Tobias Geerinckx-Rice via Guix-patches via)(address . guix-patches@gnu.org)
20200502191622.GB22384@jasmine.lan
On Sat, May 02, 2020 at 01:23:30AM +0200, Tobias Geerinckx-Rice via Guix-patches via wrote:
Toggle quote (3 lines)
> I agree with the name change, although I'm unaware of why ‘oil-shell’ was
> originally chosen.

No serious reason. I thought it was close the upstream name (it's the
GitHub organization name) and that 'oil' was a bit short for something
so obscure. Feel free to change it to 'oil' though.
-----BEGIN PGP SIGNATURE-----

iQIzBAABCAAdFiEEsFFZSPHn08G5gDigJkb6MLrKfwgFAl6txwIACgkQJkb6MLrK
fwhVkQ//TVfi2tSsdqDokrm37vREH9dlHwXQuKA4OSApQM9kp4bIEoyVAIYV8Vs6
+Aiif8L/p0LKlkJb9Yx90BLVxE2TgRGSsUI+hJUIF6ODNWe9eAynQ353pQqO2Vx9
M45boKO/7Z9Nt7VP7uX4hPi8AUv79grJjpbhF5STPY6XTSF1GvmVGCEIZbjTNRHY
a7ryxNK5V5v+UBvQE6m42qICPVs9c0GvO3v872LeX6Z5SVK7TNnSkzG7+vLtgHT6
AqebR7/Id2lJLRVObIMIJfOBS/hxrlaT2EZUDW6CXFmSqkzesVHsoWuMiF0R1w6r
+OOMMNublHLSfW44imm7RaOv3edU0fBQqI2iLeeO5M01SAFPhu82LmpjHOTxh/dr
Y6jCrJZjs8ZscQvvibOszwFePLgASv1vQJgj/aoc+JeCH+3ifn+IPAZlsp+02PHt
HUgoLKFRolI3tFmZKSynY7Q6LsCP8adr2ZL24e6G+MmKq8KMFs5vloOuWg3yDdU/
Mpg6mBGjX3EbMyc6fjEs5lUMal7T0b/+Xemn0X1IPJbQOX33ohp899tCSD5xJoLj
cb884RBBgkIIf/iZ4rNO16wl+qmxZZ/hNQdnk1PShkxBqyW1pXWP24USOqENpvVV
9+XIX9MBr8hF7aOSkXv6fSWdlX4noyi93y/9ecM9z9LQgPX3qPc=
=3Vb9
-----END PGP SIGNATURE-----


R
R
Ryan Prior wrote on 15 May 2020 19:10
(name . 41010@debbugs.gnu.org)(address . 41010@debbugs.gnu.org)
87sgg16s51.fsf@protonmail.com
Ryan Prior <rprior@protonmail.com> writes:

Toggle quote (2 lines)
> Tobias, thank you for the quick and thorough review! I've attached updated patches.

Any thoughts on this updated patch would be welcome if there are still
issues to be address before merging!

Thanks,
Ryan
T
T
Tobias Geerinckx-Rice wrote on 15 May 2020 20:31
(name . Ryan Prior)(address . rprior@protonmail.com)(name . 41010@debbugs.gnu.org)(address . 41010@debbugs.gnu.org)
878shtjbiy.fsf@nckx
Ryan,

Ryan Prior ???
Toggle quote (2 lines)
> Tobias, thank you for the quick and thorough review!

I've made up for that now \o/

Toggle quote (2 lines)
> I've attached updated patches.

Thanks. I promise I'll respond to the rest of your mail later
to(euro-)night.

My ~/guix is a dusty mess from the previous weeks and your
‘Update’ patch doesn't apply yet.

Kind regards,

T G-R
-----BEGIN PGP SIGNATURE-----

iHUEARYKAB0WIQT12iAyS4c9C3o4dnINsP+IT1VteQUCXr7f5QAKCRANsP+IT1Vt
eX5RAQCh2w50kz8Y3K76Qio9+DJLRJYPUqHV9JBOohTb4mAJyAEAys4rZDqsIo31
SZNS/gx548+5QwMT8IlikQAFkF3qEA8=
=gczt
-----END PGP SIGNATURE-----

T
T
Tobias Geerinckx-Rice wrote on 16 May 2020 13:20
(name . Ryan Prior)(address . rprior@protonmail.com)(name . 41010@debbugs.gnu.org)(address . 41010@debbugs.gnu.org)
87v9kwnn32.fsf@nckx
Ryan Prior ???
Toggle quote (2 lines)
> [2. text/x-patch; 0001-gnu-oil-Update-to-0.8.pre4.patch]...

Unfortunately I still can't apply this onto upstream/master:

Applying: gnu: oil: Update to 0.8.pre4
error: sha1 information is lacking or useless
(gnu/packages/shells.scm).
error: could not build fake ancestor
Patch failed at 0001 gnu: oil: Update to 0.8.pre4

Kind regards,

T G-R
-----BEGIN PGP SIGNATURE-----

iHUEARYKAB0WIQT12iAyS4c9C3o4dnINsP+IT1VteQUCXr/MYQAKCRANsP+IT1Vt
ea50AQDvccKSsnKezzYrLmgCquj7pwH4tx1VFRDIc2DtMR6VpgD+KKhgw1KWanZs
bESOSRVohvpPRI+VVk38Id9a+S3WEws=
=x3fp
-----END PGP SIGNATURE-----

R
R
Ryan Prior wrote on 17 May 2020 08:14
(name . Tobias Geerinckx-Rice)(address . me@tobias.gr)(name . 41010@debbugs.gnu.org)(address . 41010@debbugs.gnu.org)
87o8qnkrz9.fsf@protonmail.com
Tobias Geerinckx-Rice <me@tobias.gr> writes:

Toggle quote (2 lines)
> Unfortunately I still can't apply this onto upstream/master:

I rebased my branch off of master and created a new patch, attached.
Hope that helps!

Ryan
From ec658018df50a7463564a5877ab60945451c6052 Mon Sep 17 00:00:00 2001
From: Ryan Prior <rprior@protonmail.com>
Date: Fri, 1 May 2020 14:49:42 -0500
Subject: [PATCH 1/1] gnu: oil: Update to 0.8.pre4

gnu/packages/shells.scm (oil): Update to 0.8.pre4.
---
gnu/packages/shells.scm | 56 ++++++++++++++++++++---------------------
1 file changed, 27 insertions(+), 29 deletions(-)

Toggle diff (88 lines)
diff --git a/gnu/packages/shells.scm b/gnu/packages/shells.scm
index 5c8c4b5d8a..1582236873 100644
--- a/gnu/packages/shells.scm
+++ b/gnu/packages/shells.scm
@@ -14,6 +14,7 @@
;;; Copyright © 2019 Mathieu Othacehe <m.othacehe@gmail.com>
;;; Copyright © 2019, 2020 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
;;; Copyright © 2020 Brice Waegeneire <brice@waegenei.re>
+;;; Copyright © 2020 Ryan Prior <rprior@protonmail.com>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -783,47 +784,44 @@ Shell (pdksh).")
(define-public oil
(package
(name "oil")
- (version "0.7.0")
- (source (origin
- (method url-fetch)
- (uri (string-append "https://www.oilshell.org/download/oil-"
- version ".tar.xz"))
- (sha256
- (base32
- "12c9s462879adb6mwd3fqafk0dnqsm16s18rhym6cmzfzy8v8zm3"))))
+ (version "0.8.pre4") ; https://www.oilshell.org/blog/2020/04/release-0.8.pre4.html#comment-on-version-numbering
+ (source
+ (origin
+ (method url-fetch)
+ (uri (string-append "https://www.oilshell.org/download/oil-"
+ version ".tar.gz"))
+ (sha256
+ (base32 "0m2p8p5hi2r14xx9pphsa0ar56kqsa33gr2w2blc3jx07aqhjpzy"))))
(build-system gnu-build-system)
(arguments
- '(#:tests? #f ; the tests are not distributed in the tarballs
- #:strip-binaries? #f ; the binaries cannot be stripped
+ `(#:strip-binaries? #f ; strip breaks the binary
#:phases
(modify-phases %standard-phases
- (add-after 'unpack 'patch-compiler-invocation
- (lambda _
- (substitute* "configure"
- ((" cc ") " gcc "))
- #t))
(replace 'configure
(lambda* (#:key outputs #:allow-other-keys)
(let ((out (assoc-ref outputs "out")))
(setenv "CC" "gcc")
- ;; The configure script doesn't recognize CONFIG_SHELL.
- (setenv "CONFIG_SHELL" (which "sh"))
- (invoke "./configure" (string-append "--prefix=" out)
+ (substitute* "configure"
+ ((" cc ") " gcc "))
+ (invoke "./configure"
+ (string-append "--prefix=" out)
"--with-readline"))))
- (add-before 'install 'make-destination
+ (replace 'check
+ ;; The tests are not distributed in the tarballs but upstream
+ ;; recommends running this smoke test.
+ ;; https://github.com/oilshell/oil/blob/release/0.8.pre4/INSTALL.txt#L38-L48
(lambda _
- ;; The build scripts don't create the destination directory.
- (mkdir-p (string-append (assoc-ref %outputs "out") "/bin")))))))
+ (let* ((oil "_bin/oil.ovm"))
+ (invoke/quiet oil "osh" "-c" "echo hi")
+ (invoke/quiet oil "osh" "-n" "configure")))))))
(inputs
`(("readline" ,readline)))
- (synopsis "Bash-compatible Unix shell")
- (description "Oil is a Unix / POSIX shell, compatible with Bash. It
-implements the Oil language, which is a new shell language to which Bash can be
-automatically translated. The Oil language is a superset of Bash. It also
-implements the OSH language, a statically-parseable language based on Bash as it
-is commonly written.")
- (home-page "https://www.oilshell.org/")
- (license (list psfl ; The Oil sources include a patched Python 2 source tree
+ (home-page "https://www.oilshell.org")
+ (synopsis "Programming language and Bash-compatible Unix shell")
+ (description "Oil is a programming language with automatic translation for
+Bash. It includes osh, a Unix/POSIX shell that runs unmodified Bash
+scripts.")
+ (license (list psfl ; tarball includes python2.7
asl2.0))))
(define-public oil-shell
--
2.17.1
R
R
Ryan Prior wrote on 29 May 2020 01:38
[PATCH 0/1] Updated patch for 0.8.pre5
(address . 41010@debbugs.gnu.org)
20200528233825.15320-1-rprior@protonmail.com
The best upstream release is now 0.8.pre5, so here's a patch updated for that version.

Ryan Prior (1):
gnu: oil: Update to 0.8.pre5

gnu/packages/shells.scm | 56 ++++++++++++++++++++---------------------
1 file changed, 27 insertions(+), 29 deletions(-)

--
2.26.2
R
R
Ryan Prior wrote on 29 May 2020 01:38
[PATCH 1/1] gnu: oil: Update to 0.8.pre5
(address . 41010@debbugs.gnu.org)
20200528233825.15320-2-rprior@protonmail.com
gnu/packages/shells.scm (oil): Update to 0.8.pre5.
---
gnu/packages/shells.scm | 56 ++++++++++++++++++++---------------------
1 file changed, 27 insertions(+), 29 deletions(-)

Toggle diff (88 lines)
diff --git a/gnu/packages/shells.scm b/gnu/packages/shells.scm
index fa3eccabd4..147ba24c3f 100644
--- a/gnu/packages/shells.scm
+++ b/gnu/packages/shells.scm
@@ -14,6 +14,7 @@
;;; Copyright © 2019 Mathieu Othacehe <m.othacehe@gmail.com>
;;; Copyright © 2019, 2020 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
;;; Copyright © 2020 Brice Waegeneire <brice@waegenei.re>
+;;; Copyright © 2020 Ryan Prior <rprior@protonmail.com>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -793,47 +794,44 @@ Shell (pdksh).")
(define-public oil
(package
(name "oil")
- (version "0.7.0")
- (source (origin
- (method url-fetch)
- (uri (string-append "https://www.oilshell.org/download/oil-"
- version ".tar.xz"))
- (sha256
- (base32
- "12c9s462879adb6mwd3fqafk0dnqsm16s18rhym6cmzfzy8v8zm3"))))
+ (version "0.8.pre5") ; https://www.oilshell.org/blog/2020/04/release-0.8.pre4.html#comment-on-version-numbering
+ (source
+ (origin
+ (method url-fetch)
+ (uri (string-append "https://www.oilshell.org/download/oil-"
+ version ".tar.gz"))
+ (sha256
+ (base32 "02llxx10izxpv1y32qn8k6r0y7al01rzxjirc8h6x8nd9kiaqknl"))))
(build-system gnu-build-system)
(arguments
- '(#:tests? #f ; the tests are not distributed in the tarballs
- #:strip-binaries? #f ; the binaries cannot be stripped
+ `(#:strip-binaries? #f ; strip breaks the binary
#:phases
(modify-phases %standard-phases
- (add-after 'unpack 'patch-compiler-invocation
- (lambda _
- (substitute* "configure"
- ((" cc ") " gcc "))
- #t))
(replace 'configure
(lambda* (#:key outputs #:allow-other-keys)
(let ((out (assoc-ref outputs "out")))
(setenv "CC" "gcc")
- ;; The configure script doesn't recognize CONFIG_SHELL.
- (setenv "CONFIG_SHELL" (which "sh"))
- (invoke "./configure" (string-append "--prefix=" out)
+ (substitute* "configure"
+ ((" cc ") " gcc "))
+ (invoke "./configure"
+ (string-append "--prefix=" out)
"--with-readline"))))
- (add-before 'install 'make-destination
+ (replace 'check
+ ;; The tests are not distributed in the tarballs but upstream
+ ;; recommends running this smoke test.
+ ;; https://github.com/oilshell/oil/blob/release/0.8.pre5/INSTALL.txt#L38-L48
(lambda _
- ;; The build scripts don't create the destination directory.
- (mkdir-p (string-append (assoc-ref %outputs "out") "/bin")))))))
+ (let* ((oil "_bin/oil.ovm"))
+ (invoke/quiet oil "osh" "-c" "echo hi")
+ (invoke/quiet oil "osh" "-n" "configure")))))))
(inputs
`(("readline" ,readline)))
- (synopsis "Bash-compatible Unix shell")
- (description "Oil is a Unix / POSIX shell, compatible with Bash. It
-implements the Oil language, which is a new shell language to which Bash can be
-automatically translated. The Oil language is a superset of Bash. It also
-implements the OSH language, a statically-parseable language based on Bash as it
-is commonly written.")
- (home-page "https://www.oilshell.org/")
- (license (list psfl ; The Oil sources include a patched Python 2 source tree
+ (home-page "https://www.oilshell.org")
+ (synopsis "Programming language and Bash-compatible Unix shell")
+ (description "Oil is a programming language with automatic translation for
+Bash. It includes osh, a Unix/POSIX shell that runs unmodified Bash
+scripts.")
+ (license (list psfl ; tarball includes python2.7
asl2.0))))
(define-public oil-shell
--
2.26.2
T
T
Tobias Geerinckx-Rice wrote on 29 May 2020 06:48
Re: [bug#41010] [PATCH 0/1] Updated patch for 0.8.pre5
(name . Ryan Prior)(address . rprior@protonmail.com)(address . 41010-done@debbugs.gnu.org)
87r1v32vop.fsf@nckx
Ryan,

Ryan Prior via Guix-patches via ???
Toggle quote (3 lines)
> The best upstream release is now 0.8.pre5, so here's a patch
> updated for that version.

Pushed as 01914fd2bbad199df89b1cac2c72b453e57685ff with a
completed commit message and the previously suggested gcc → $CC
change.

Thanks!

T G-R
-----BEGIN PGP SIGNATURE-----

iHUEARYKAB0WIQT12iAyS4c9C3o4dnINsP+IT1VteQUCXtCUFgAKCRANsP+IT1Vt
efZVAP9CAN6Ndx7TfN3bf/rFO8nssGU5axqG4ul/qPYktGR79wD/cFp+khtpvWhO
83trvzUj8Jbh6MyFddo9OzjbiKK7MwM=
=XC6i
-----END PGP SIGNATURE-----

Closed
?