From mboxrd@z Thu Jan 1 00:00:00 1970 From: Alex Kost Subject: Re: [PATCH 4/7] emacs: Add 'guix-devel-use-current-module'. Date: Wed, 19 Aug 2015 23:47:42 +0300 Message-ID: <87a8tn2efl.fsf@gmail.com> References: <1437814197-6321-1-git-send-email-alezost@gmail.com> <1437814197-6321-5-git-send-email-alezost@gmail.com> <87h9nwvgi3.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:36154) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZSAGu-0000DD-Md for guix-devel@gnu.org; Wed, 19 Aug 2015 16:47:45 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZSAGp-0003XP-O3 for guix-devel@gnu.org; Wed, 19 Aug 2015 16:47:44 -0400 In-Reply-To: <87h9nwvgi3.fsf@gnu.org> ("Ludovic \=\?utf-8\?Q\?Court\=C3\=A8s\=22'\?\= \=\?utf-8\?Q\?s\?\= message of "Tue, 18 Aug 2015 16:05:40 +0200") List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org To: Ludovic =?utf-8?Q?Court=C3=A8s?= Cc: guix-devel@gnu.org Ludovic Court=C3=A8s (2015-08-18 17:05 +0300) wrote: > Alex Kost skribis: > >> * emacs/guix-guile.el (guix-guile-current-module): New function. >> * emacs/guix-devel.el: New file. >> (guix-devel-use-modules, guix-devel-use-current-module): New functions. >> * doc/emacs.texi (Emacs Development): New node. Document >> 'guix-devel-use-current-module'. > > [...] > >> +@node Emacs Development >> +@subsection Development >> + >> +This section describes some additional commands for Guix developers who >> +use Geiser to work with guile code. > > s/guile/Guile/ > > It=E2=80=99s fine to leave this section here, but there should be a sente= nce > under =E2=80=9CContributing=E2=80=9D with a cross-reference to here. OK. >> +@table @kbd >> + >> +@item M-x guix-devel-use-current-module >> +Use the current guile module. Often after opening a scheme file, you > > Capitalize =E2=80=9CGuile=E2=80=9D and =E2=80=9CScheme=E2=80=9D here. > >> +want to use a module it defines, so you switch to the Geiser REPL and >> +write @code{,use (some module)} there. You may just use this command >> +instead. > > Could you mention a use case here? Like: > > For instance, you may call this command while visiting a file that > defines packages; you can then switch to the associated REPL with > @kbd{C-c C-z}, which will be in the current module, which is handy. The REPL will not be in the current module. "M-x guix-devel-use-current-module" is the equivalent of ",use", not ",module". I thought the documentation was clear about that, no? For switching to the current module, Geiser provides "C-c C-a" or "C-u C-c C-z". > The =E2=80=9C-devel=E2=80=9D part might make it sound like it has an effe= ct similar to > =E2=80=98pre-inst-env=E2=80=99 though. Perhaps we should explicitly remi= nd developers > that they must set =E2=80=98guix-load-path=E2=80=99 appropriately? Setting =E2=80=98guix-load-path=E2=80=99 will not take any effect here. Th= e whole point of this guix-devel stuff is to provide additional commands for scheme-mode, like Geiser does. And these additional commands are independent from Guix REPL; they are called in the current Geiser REPL the same way you would use other Geiser commands. So, for example, you open some guile file, you press some key bound to =E2=80=98guix-devel-use-current-module=E2=80=99 command to use this module = in the current Geiser REPL. Then (if it's a module with guix packages), you press another key to build the current package, or (in future) to download the current package source, etc. > Otherwise OK, thanks! Thank you! --=20 Alex