* [PATCH 3/3] gnu: Add emacs-ledger-mode.
@ 2016-05-07 18:42 Alex Griffin
2016-05-07 22:23 ` Leo Famulari
2016-05-08 7:46 ` Alex Kost
0 siblings, 2 replies; 6+ messages in thread
From: Alex Griffin @ 2016-05-07 18:42 UTC (permalink / raw)
To: guix-devel
[-- Attachment #1: Type: text/plain, Size: 252 bytes --]
This is the Emacs mode for manipulating ledger files. Technically it
depends on ledger but it would have need to be a propagated input, so I
didn't include that. Maybe I should have? I don't know.
Thanks in advance for your feedback,
--
Alex Griffin
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0003-gnu-Add-emacs-ledger-mode.patch --]
[-- Type: text/x-patch; name="0003-gnu-Add-emacs-ledger-mode.patch", Size: 2222 bytes --]
From 639402e17e19f21373d935d4bfe0f506c53f77be Mon Sep 17 00:00:00 2001
From: Alex Griffin <a@ajgrf.com>
Date: Sat, 7 May 2016 12:22:15 -0500
Subject: [PATCH 3/3] gnu: Add emacs-ledger-mode.
* gnu/packages/emacs.scm (emacs-ledger-mode): New variable.
---
gnu/packages/emacs.scm | 31 +++++++++++++++++++++++++++++++
1 file changed, 31 insertions(+)
diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm
index 11010b2..3d9ac06 100644
--- a/gnu/packages/emacs.scm
+++ b/gnu/packages/emacs.scm
@@ -7,6 +7,7 @@
;;; Copyright © 2015, 2016 Ricardo Wurmus <rekado@elephly.net>
;;; Copyright © 2016 Nils Gillmann <niasterisk@grrlz.net>
;;; Copyright © 2016 Chris Marusich <cmmarusich@gmail.com>
+;;; Copyright © 2016 Alex Griffin <a@ajgrf.com>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -1559,3 +1560,33 @@ to recognize a name like \"RFC 1234\". This package enhances ffap so
that it correctly finds RFCs even when a space appears before the
number.")
(license license:gpl3+)))
+
+(define-public emacs-ledger-mode
+ (package
+ (name "emacs-ledger-mode")
+ (version "3.1.1")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "https://github.com/ledger/ledger/archive/v" version
+ ".tar.gz"))
+ (file-name (string-append name "-" version ".tar.gz"))
+ (sha256
+ (base32
+ "12jlv3gsjhrja25q9hrwh73cdacd2l3c2yyn8qnijav9mdhnbw4h"))))
+ (build-system emacs-build-system)
+ (arguments
+ `(#:phases
+ (modify-phases %standard-phases
+ (add-before 'install 'elisp-subdir
+ (lambda _
+ (begin (chdir "lisp")
+ (delete-file "CMakeLists.txt"))
+ #t)))))
+ (home-page "http://ledger-cli.org/")
+ (synopsis "Emacs mode for working with \"ledger\" accounting data")
+ (description
+ "Ledger is a powerful, double-entry accounting system that is
+ accessed from the UNIX command-line. This package contains an
+ Emacs mode for manipulating ledger's text-based file format,
+ running reports on it, reconciling its accounts, and more.")
+ (license license:gpl2+)))
--
2.7.4
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH 3/3] gnu: Add emacs-ledger-mode.
2016-05-07 18:42 [PATCH 3/3] gnu: Add emacs-ledger-mode Alex Griffin
@ 2016-05-07 22:23 ` Leo Famulari
2016-05-08 2:10 ` Alex Griffin
2016-05-08 7:46 ` Alex Kost
1 sibling, 1 reply; 6+ messages in thread
From: Leo Famulari @ 2016-05-07 22:23 UTC (permalink / raw)
To: Alex Griffin; +Cc: guix-devel
On Sat, May 07, 2016 at 01:42:09PM -0500, Alex Griffin wrote:
> This is the Emacs mode for manipulating ledger files. Technically it
> depends on ledger but it would have need to be a propagated input, so I
> didn't include that. Maybe I should have? I don't know.
Somebody else will have to test that this works; I don't know enough
about Emacs to try it.
> * gnu/packages/emacs.scm (emacs-ledger-mode): New variable.
> + (package
> + (name "emacs-ledger-mode")
> + (version "3.1.1")
> + (source (origin
Would it be appropriate to use (package-version ledger) and
(package-source ledger), as in the package definition of tocc?
That way, updating ledger would automatically update emacs-ledger-mode
as well.
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH 3/3] gnu: Add emacs-ledger-mode.
2016-05-07 22:23 ` Leo Famulari
@ 2016-05-08 2:10 ` Alex Griffin
0 siblings, 0 replies; 6+ messages in thread
From: Alex Griffin @ 2016-05-08 2:10 UTC (permalink / raw)
To: Leo Famulari; +Cc: guix-devel
[-- Attachment #1: Type: text/plain, Size: 523 bytes --]
On Sat, May 7, 2016, at 05:23 PM, Leo Famulari wrote:
> Somebody else will have to test that this works; I don't know enough
> about Emacs to try it.
Well it seems to work on my machine, but I guess the whole point of code
review is that somebody checks it other than me.
> Would it be appropriate to use (package-version ledger) and
> (package-source ledger), as in the package definition of tocc?
>
> That way, updating ledger would automatically update emacs-ledger-mode
> as well.
Good idea, done.
--
Alex Griffin
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0003-gnu-Add-emacs-ledger-mode.patch --]
[-- Type: text/x-patch; name="0003-gnu-Add-emacs-ledger-mode.patch", Size: 2116 bytes --]
From fe7cee618e43bfdba7e39d058676429235a17c56 Mon Sep 17 00:00:00 2001
From: Alex Griffin <a@ajgrf.com>
Date: Sat, 7 May 2016 12:22:15 -0500
Subject: [PATCH 3/3] gnu: Add emacs-ledger-mode.
* gnu/packages/emacs.scm (emacs-ledger-mode): New variable.
---
gnu/packages/emacs.scm | 25 +++++++++++++++++++++++++
1 file changed, 25 insertions(+)
diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm
index 11010b2..69a85ef 100644
--- a/gnu/packages/emacs.scm
+++ b/gnu/packages/emacs.scm
@@ -7,6 +7,7 @@
;;; Copyright © 2015, 2016 Ricardo Wurmus <rekado@elephly.net>
;;; Copyright © 2016 Nils Gillmann <niasterisk@grrlz.net>
;;; Copyright © 2016 Chris Marusich <cmmarusich@gmail.com>
+;;; Copyright © 2016 Alex Griffin <a@ajgrf.com>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -63,6 +64,7 @@
#:use-module (gnu packages scheme)
#:use-module (gnu packages xiph)
#:use-module (gnu packages mp3)
+ #:use-module (gnu packages finance)
#:use-module (guix utils)
#:use-module (srfi srfi-1))
@@ -1559,3 +1561,26 @@ to recognize a name like \"RFC 1234\". This package enhances ffap so
that it correctly finds RFCs even when a space appears before the
number.")
(license license:gpl3+)))
+
+(define-public emacs-ledger-mode
+ (package
+ (name "emacs-ledger-mode")
+ (version (package-version ledger))
+ (source (package-source ledger))
+ (build-system emacs-build-system)
+ (arguments
+ `(#:phases
+ (modify-phases %standard-phases
+ (add-before 'install 'elisp-subdir
+ (lambda _
+ (begin (chdir "lisp")
+ (delete-file "CMakeLists.txt"))
+ #t)))))
+ (home-page "http://ledger-cli.org/")
+ (synopsis "Emacs mode for working with \"ledger\" accounting data")
+ (description
+ "Ledger is a powerful, double-entry accounting system that is
+ accessed from the UNIX command-line. This package contains an
+ Emacs mode for manipulating ledger's text-based file format,
+ running reports on it, reconciling its accounts, and more.")
+ (license license:gpl2+)))
--
2.7.4
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH 3/3] gnu: Add emacs-ledger-mode.
2016-05-07 18:42 [PATCH 3/3] gnu: Add emacs-ledger-mode Alex Griffin
2016-05-07 22:23 ` Leo Famulari
@ 2016-05-08 7:46 ` Alex Kost
2016-05-09 3:33 ` Leo Famulari
1 sibling, 1 reply; 6+ messages in thread
From: Alex Kost @ 2016-05-08 7:46 UTC (permalink / raw)
To: Alex Griffin; +Cc: guix-devel
Alex Griffin (2016-05-07 21:42 +0300) wrote:
> This is the Emacs mode for manipulating ledger files. Technically it
> depends on ledger but it would have need to be a propagated input, so I
> didn't include that. Maybe I should have? I don't know.
As for me, I think this emacs stuff shouldn't be extracted from 'ledger'
package. We don't do this for other packages: for example, 'mu' has an
emacs interface (called 'mu4e'); 'asymptote' will have too (discussed in
a separate thread¹); and 'guix' itself has some elisp code.
So I think there is no need to make a separate 'emacs-ledger-mode'
package, but instead 'ledger' package should be adjusted (if needed) to
put elisp files in appropriate place.
> + (description
> + "Ledger is a powerful, double-entry accounting system that is
> + accessed from the UNIX command-line. This package contains an
> + Emacs mode for manipulating ledger's text-based file format,
> + running reports on it, reconciling its accounts, and more.")
I see that you add leading spaces on each line inside your
descriptions. There is no need to do it, just:
(description
"Ledger is a powerful, double-entry accounting system that
is accessed from the UNIX command-line. This package contains an
Emacs mode for manipulating ledger's text-based file format,
running reports on it, reconciling its accounts, and more.")
¹ http://lists.gnu.org/archive/html/guix-devel/2016-05/msg00206.html
--
Alex
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH 3/3] gnu: Add emacs-ledger-mode.
2016-05-08 7:46 ` Alex Kost
@ 2016-05-09 3:33 ` Leo Famulari
2016-05-10 23:34 ` Alex Griffin
0 siblings, 1 reply; 6+ messages in thread
From: Leo Famulari @ 2016-05-09 3:33 UTC (permalink / raw)
To: Alex Kost; +Cc: guix-devel
On Sun, May 08, 2016 at 10:46:59AM +0300, Alex Kost wrote:
> Alex Griffin (2016-05-07 21:42 +0300) wrote:
>
> > This is the Emacs mode for manipulating ledger files. Technically it
> > depends on ledger but it would have need to be a propagated input, so I
> > didn't include that. Maybe I should have? I don't know.
>
> As for me, I think this emacs stuff shouldn't be extracted from 'ledger'
> package. We don't do this for other packages: for example, 'mu' has an
> emacs interface (called 'mu4e'); 'asymptote' will have too (discussed in
> a separate thread¹); and 'guix' itself has some elisp code.
>
> So I think there is no need to make a separate 'emacs-ledger-mode'
> package, but instead 'ledger' package should be adjusted (if needed) to
> put elisp files in appropriate place.
Sounds good to me!
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH 3/3] gnu: Add emacs-ledger-mode.
2016-05-09 3:33 ` Leo Famulari
@ 2016-05-10 23:34 ` Alex Griffin
0 siblings, 0 replies; 6+ messages in thread
From: Alex Griffin @ 2016-05-10 23:34 UTC (permalink / raw)
To: Leo Famulari, Alex Kost; +Cc: guix-devel
On Sun, May 8, 2016, at 10:33 PM, Leo Famulari wrote:
> On Sun, May 08, 2016 at 10:46:59AM +0300, Alex Kost wrote:
> > So I think there is no need to make a separate 'emacs-ledger-mode'
> > package, but instead 'ledger' package should be adjusted (if needed) to
> > put elisp files in appropriate place.
>
> Sounds good to me!
Okay, I will roll this up into the ledger package then. I've been
distracted for a couple days, but it should come soon now.
--
Alex Griffin
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2016-05-10 23:35 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-05-07 18:42 [PATCH 3/3] gnu: Add emacs-ledger-mode Alex Griffin
2016-05-07 22:23 ` Leo Famulari
2016-05-08 2:10 ` Alex Griffin
2016-05-08 7:46 ` Alex Kost
2016-05-09 3:33 ` Leo Famulari
2016-05-10 23:34 ` Alex Griffin
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).