diff options
author | Alex Kost <alezost@gmail.com> | 2014-10-16 21:35:47 +0400 |
---|---|---|
committer | Alex Kost <alezost@gmail.com> | 2014-10-17 10:56:27 +0400 |
commit | 189cea2782df67ea048a3982be69c8b1ff9762e9 (patch) | |
tree | f353da6c0b24a43cfad0da4635e3deaa7f7b1d71 /emacs/guix.el | |
parent | 347e17b47450a0fcc120c29e8b307e87b9182c21 (diff) | |
download | guix-189cea2782df67ea048a3982be69c8b1ff9762e9.tar guix-189cea2782df67ea048a3982be69c8b1ff9762e9.tar.gz |
emacs: Add 'guix-generations-by-time' command.
* emacs/guix-main.scm (find-generations): Add finding generations by time.
* emacs/guix-utils.el (guix-read-date): New procedure.
* emacs/guix-base.el (guix-messages): Add new messages.
* emacs/guix.el (guix-generations-by-time): New command.
* doc/emacs.texi (emacs Commands): Document it.
Diffstat (limited to 'emacs/guix.el')
-rw-r--r-- | emacs/guix.el | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/emacs/guix.el b/emacs/guix.el index a1425161c4..b91a88dc14 100644 --- a/emacs/guix.el +++ b/emacs/guix.el @@ -31,6 +31,7 @@ (require 'guix-base) (require 'guix-list) (require 'guix-info) +(require 'guix-utils) (defgroup guix nil "Interface for Guix package manager." @@ -134,6 +135,17 @@ Interactively, NUMBER is defined by a numeric prefix." (guix-get-show-generations 'last number) (guix-get-show-generations 'all))) +;;;###autoload +(defun guix-generations-by-time (from to) + "Display information about generations created between FROM and TO. +FROM and TO should be time values." + (interactive + (list (guix-read-date "Find generations (from): ") + (guix-read-date "Find generations (to): "))) + (guix-get-show-generations 'time + (float-time from) + (float-time to))) + (provide 'guix) ;;; guix.el ends here |