Commit graph

7 commits

Author SHA1 Message Date
Alex Kost
10b0c31d6b emacs: Simplify 'guix-guile-boolean'.
* emacs/guix-guile.el (guix-guile-boolean): Use straightforward way to
  define true/false value.
2016-05-10 12:05:53 +03:00
Alex Kost
5a60d56975 emacs: Fix 'guix-devel-setup-repl'.
Setting up guix ports needs to be done in Geiser REPL synchronously,
otherwise this operation may not be finished before the further
evaluating of guile code.

* emacs/guix-guile.el (guix-guile-prompt?): New function.
* emacs/guix-geiser.el (guix-geiser-eval-in-repl-synchronously): New
  function.
* emacs/guix-devel.el (guix-devel-setup-repl): Use it.
2015-10-09 16:17:45 +03:00
Alex Kost
730bf80888 emacs: devel: Highlight 'modify-phases' keywords.
* emacs/guix-guile.el (guix-guile-keyword-regexp): New function.
* emacs/guix-devel.el (guix-devel-faces): New custom group.
  (guix-devel-modify-phases-keyword): New face.
  (guix-devel-modify-phases-keyword-regexp,
  guix-devel-font-lock-keywords): New variables.
  (guix-devel-modify-phases-font-lock-matcher,
  guix-devel-modify-phases-font-lock-pre): New functions.
  (guix-devel-mode): Adjust to add/remove font-lock-keywords.
2015-09-26 22:38:43 +03:00
Alex Kost
1a6c4c2f37 emacs: Add 'guix-devel-build-package-definition'.
Suggested by Ludovic Courtès <ludo@gnu.org>.

* emacs/guix-guile.el (guix-guile-definition-regexp): New variable.
  (guix-guile-current-definition, guix-guile-boolean): New functions.
* emacs/guix-devel.el: Require 'guix-base'.
  (guix-devel-repl-processes): New variable.
  (guix-devel-setup-repl, guix-devel-setup-repl-maybe): New functions.
  (guix-devel-build-package-definition): New command.
* doc/emacs.texi (Emacs Development): Document it.
2015-09-23 13:36:37 +03:00
Alex Kost
187f80c6c5 emacs: Add development utils.
* emacs/guix-guile.el (guix-guile-current-module): New function.
* emacs/guix-devel.el: New file.
* emacs.am (ELFILES): Add it.
* doc/emacs.texi (Emacs Development): New node.
  (Emacs Interface): Add it.
* doc/contributing.texi (The Perfect Setup): Mention it.
* doc/guix.texi (Top): Add it.
* emacs/guix-init.el: Add 'guix-devel-activate-mode-maybe' to
  'scheme-mode-hook'.
2015-09-23 13:36:37 +03:00
Alex Kost
f80a7a6c58 emacs: Add code to call guile procedures.
* emacs/guix-guile.el (guix-guile-make-call-expression): New function.
* emacs/guix-geiser.el: Require 'guix-guile'.
  (guix-geiser-call, guix-geiser-call-in-repl): New functions.
2015-09-22 22:05:10 +03:00
Alex Kost
c74cd6cc12 emacs: Move guile related code to "guix-guile.el".
* emacs/guix-backend.el (guix-make-guile-expression): Move to...
* emacs/guix-guile.el: ... here.  New file.
* emacs/guix-base.el: Use it.
* emacs/guix-command.el: Use it.
* emacs.am (ELFILES): Add it.
2015-09-22 22:05:09 +03:00