[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [ANN] Emacs-Guix 0.3.4

From: Oleg Pykhalov
Subject: Re: [ANN] Emacs-Guix 0.3.4
Date: Fri, 29 Dec 2017 20:44:11 +0300
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.3 (gnu/linux)

Hello Alex, Guix

Alex Kost <address@hidden> writes:

> Hello, Emacs-Guix (Emacs interface for GNU Guix) version 0.3.4 has been
> released.  It may be installed with "guix package -i emacs-guix".
> The main new features are:

By the way, 'guix-edit' supports a new behavior:

    Read symbol at point and if it is a package name, return it.  If it
    is not a package name or if current command has a prefix argument,
    read the name from minibuffer.

    (from 'guix-read-package-name-at-point' documentation string).

To set it up you need the following in your '.emacs':

    (setq guix-read-package-name-function

> 1. "M-x guix-hash": it prompts for a file, calculates its hash and puts
>    it into kill-ring (i.e., you can insert it with "C-y").  If it is
>    called on a directory, it ignores VCS files (like "guix hash
>    --recursive --exclude-vcs").  Also it supports dired-mode.  Thanks to
>    ng0 for the idea of this command!

I like this, but as I undertand it works only with files or directories
locally.  Could we do something like:

    (defun guix-download (url)
      (interactive "sDownload URL: ")
      (insert (shell-command-to-string (concat "guix download "
                                               " 2>/dev/null"
                                               "| tail -n 1"
                                               "| tr -d '\n'"))))

which will download a thing and paste a hash at the cursor position.

We have a 'guix-devel-download-package-source', but it basically the
same as a shell command 'guix download PACKAGE' which requires to copy
hash manually.  What we probably want is to get a hash into Emacs
kill-ring as guix-hash does.

> 2. "M-x guix-derivation-mode": this major mode makes Guix derivations
>    more human readable by indenting them and by making buttons from the
>    store file names.  It is enabled automatically in "/gnu/store/….drv"
>    files.  Many thanks to Oleg Pykhalov for inventing and implementing
>    this feature!

Thank you for leading and improvements after, too!


> Happy Guix Year :-)

Happy New Year!


Attachment: signature.asc
Description: PGP signature

reply via email to

[Prev in Thread] Current Thread [Next in Thread]