[PATCH] gnu: Add emacs-powershell.el

  • Done
  • quality assurance status badge
Details
2 participants
  • Nicolas Goaziou
  • Adam Kandur
Owner
unassigned
Submitted by
Adam Kandur
Severity
normal
A
A
Adam Kandur wrote on 28 Oct 2020 09:39
(name . Guix Patches)(address . guix-patches@gnu.org)
MKiM5Yb--3-2@tuta.io
Sometimes use it for work, would be great to have in guix,

Adam Kandur
From debe288267094e2eefff6083ac4d245020a4909d Mon Sep 17 00:00:00 2001
From: Adam <rndd@tuta.io>
Date: Wed, 28 Oct 2020 11:35:03 +0300
Subject: [PATCH] gnu: Add emacs-powershell.el

* gnu/packages/emacs-xyz.scm (emacs-powershell.el): New variable.
---
gnu/packages/emacs-xyz.scm | 23 +++++++++++++++++++++++
1 file changed, 23 insertions(+)

Toggle diff (36 lines)
diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm
index 019b2c6..8470829 100644
--- a/gnu/packages/emacs-xyz.scm
+++ b/gnu/packages/emacs-xyz.scm
@@ -25091,6 +25091,29 @@ built-in generator package. It provides @code{iter2-defun} and
original package.")
(license license:gpl3+)))
+(define-public emacs-powershell.el
+ (let ((revision "0")
+ (commit "d1b3f95669343399f199f291ef76c09a0ede5e60"))
+ (package
+ (name "emacs-powershell.el")
+ (build-system emacs-build-system)
+ (arguments
+ `(#:include '("\\.el$")))
+ (version "master") ;; tagged branch is outdated (2015)
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/jschaf/powershell.el")
+ (commit version)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32 "1cxhzaaig88zhylyycvb3849r85j1ijqklnh9zbqsfl2zhpb0g5c"))))
+ (home-page "https://github.com/jschaf/powershell.el")
+ (synopsis "Mode for editing PowerShell scripts")
+ (description "@code{powershell.el} Mode is an Emacs major mode for editing and running Microsoft PowerShell files.")
+ (license license:gpl3+))))
+
(define-public emacs-promise
(package
(name "emacs-promise")
--
2.28.0
N
N
Nicolas Goaziou wrote on 28 Oct 2020 10:27
(name . Adam Kandur via Guix-patches via)(address . guix-patches@gnu.org)
87v9eu3dkc.fsf@nicolasgoaziou.fr
Hello,

Adam Kandur via Guix-patches via <guix-patches@gnu.org> writes:

Toggle quote (2 lines)
> * gnu/packages/emacs-xyz.scm (emacs-powershell.el): New variable.

Thank you. Some comments follow.

Toggle quote (2 lines)
> +(define-public emacs-powershell.el

I suggest to rename it emacs-powershell.

Toggle quote (5 lines)
> + (let ((revision "0")
> + (commit "d1b3f95669343399f199f291ef76c09a0ede5e60"))
> + (package
> + (name "emacs-powershell.el")

See above.

Toggle quote (5 lines)
> + (build-system emacs-build-system)
> + (arguments
> + `(#:include '("\\.el$")))
> + (version "master") ;; tagged branch is outdated (2015)

Version is 0.3 per main Elisp file.

Also, end of line comments start with a single semicolon. Two semicolons
are used only for full line comments. In any case, I suggest to write
the comment above `package' instead.

Toggle quote (6 lines)
> + (source
> + (origin
> + (method git-fetch)
> + (uri (git-reference
> + (url "https://github.com/jschaf/powershell.el")

There seem to be an issue with indentation here.

Toggle quote (2 lines)
> + (commit version)))

This should be (commit commit)

Toggle quote (6 lines)
> + (file-name (git-file-name name version))
> + (sha256
> + (base32 "1cxhzaaig88zhylyycvb3849r85j1ijqklnh9zbqsfl2zhpb0g5c"))))
> + (home-page "https://github.com/jschaf/powershell.el")
> + (synopsis "Mode for editing PowerShell scripts")

I suggest:

Emacs mode for editing PowerShell scripts

Toggle quote (2 lines)
> + (description "@code{powershell.el} Mode is an Emacs major mode for editing and running Microsoft PowerShell files.")

I suggest:

Powershell is an Emacs major mode…

The library is really named Powershell, and the capitalization makes it
different from PowerShell.

Could you send an updated patch?

Regards,
--
Nicolas Goaziou
N
N
Nicolas Goaziou wrote on 28 Oct 2020 11:01
(name . Adam Kandur via Guix-patches via)(address . guix-patches@gnu.org)
87lffq3c0i.fsf@nicolasgoaziou.fr
Adam Kandur via Guix-patches via <guix-patches@gnu.org> writes:

Toggle quote (3 lines)
> + (arguments
> + `(#:include '("\\.el$")))

In addition to my other comments, I don't think the section above is
needed.

Regards,
A
A
Adam Kandur wrote on 28 Oct 2020 12:04
(name . Nicolas Goaziou)(address . mail@nicolasgoaziou.fr)(address . 44274@debbugs.gnu.org)
MKisHT9--3-2@tuta.io
hi, attached new patch. hope it is correct



Oct 28, 2020, 10:01 by mail@nicolasgoaziou.fr:

Toggle quote (11 lines)
> Adam Kandur via Guix-patches via <guix-patches@gnu.org> writes:
>
>> + (arguments
>> + `(#:include '("\\.el$")))
>>
>
> In addition to my other comments, I don't think the section above is
> needed.
>
> Regards,
>
From 288fbe826b26d088c70c876ef74afd5445b63609 Mon Sep 17 00:00:00 2001
From: Adam <rndd@tuta.io>
Date: Wed, 28 Oct 2020 14:02:26 +0300
Subject: [PATCH] gnu: Add emacs-powershell.

* gnu/packages/emacs-xyz.scm (emacs-powershell): New variable.
---
gnu/packages/emacs-xyz.scm | 22 ++++++++++++++++++++++
1 file changed, 22 insertions(+)

Toggle diff (35 lines)
diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm
index 40e4c63..6684678 100644
--- a/gnu/packages/emacs-xyz.scm
+++ b/gnu/packages/emacs-xyz.scm
@@ -13232,6 +13232,28 @@ literate programming tools for exporting, weaving and tangling.")
"Edit YAML files for Ansible containing embedded Jinja2 templating.")
(license license:gpl3+))))
+(define-public emacs-powershell
+ (let ((revision "0")
+ (commit "d1b3f95669343399f199f291ef76c09a0ede5e60"))
+ ;; tagged branch 0.1 is outdated (2015)
+ (package
+ (name "emacs-powershell")
+ (build-system emacs-build-system)
+ (version "0.3")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/jschaf/powershell.el")
+ (commit commit)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32 "1cxhzaaig88zhylyycvb3849r85j1ijqklnh9zbqsfl2zhpb0g5c"))))
+ (home-page "")
+ (synopsis "Emacs mode for editing PowerShell scripts")
+ (description "@code{powershell.el} Mode is an Emacs major mode for editing and running Microsoft PowerShell files.")
+ (license license:gpl3+))))
+
(define-public emacs-polymode-org
(package
(name "emacs-polymode-org")
--
2.28.0
N
N
Nicolas Goaziou wrote on 29 Oct 2020 10:20
(name . Adam Kandur)(address . rndd@tuta.io)(address . 44274-done@debbugs.gnu.org)
87d011mlrs.fsf@nicolasgoaziou.fr
Hello,

Adam Kandur <rndd@tuta.io> writes:

Toggle quote (2 lines)
> hi, attached new patch. hope it is correct

I fixed indentation, the version tag, added a home-page, tweaked the
description, and pushed your patch.

Thanks.

Regards,
--
Nicolas Goaziou
Closed
?