From mboxrd@z Thu Jan 1 00:00:00 1970 From: Mekeor Melire Subject: Re: Tool to format/indent scheme code Date: Sat, 04 Mar 2017 15:18:12 +0100 Message-ID: <87mvd1jfbv.fsf@gmail.com> References: <878tolwprw.fsf@163.com> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:45832) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ckAVm-0002DU-AN for help-guix@gnu.org; Sat, 04 Mar 2017 09:18:19 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ckAVl-0001Li-At for help-guix@gnu.org; Sat, 04 Mar 2017 09:18:18 -0500 Received: from mail-wm0-x230.google.com ([2a00:1450:400c:c09::230]:38577) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1ckAVl-0001KK-3a for help-guix@gnu.org; Sat, 04 Mar 2017 09:18:17 -0500 Received: by mail-wm0-x230.google.com with SMTP id t193so34325258wmt.1 for ; Sat, 04 Mar 2017 06:18:15 -0800 (PST) In-reply-to: <878tolwprw.fsf@163.com> List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-guix-bounces+gcggh-help-guix=m.gmane.org@gnu.org Sender: "Help-Guix" To: "Huang, Ying" Cc: help-guix Huang, Ying writes: > Sometimes, I want to check the contents of auto-generated scheme code in > store. But the readability is not very good. So I want to use a code > format/indent tool to help on this. Do you know is there such tool in > Guix? If no, any tool not in Guix? Thanks in advance! In Guix' Git-repository, there is a file `etc/indent-code.el.in`. I think, after running `./bootstrap`, it becomes `etc/indent-code.el` which is then executable. I guess, it requires emacs being installed though. You can then run `./etc/indent-code.el gnu/packages/foo.scm` or so. I'm not sure if `indent-code.el` is only made for package definitions (like gnu/packages/foo.scm) or if it also works for other Scheme code. Maybe try it? Maybe somebody else knows? Maybe read the code? I'm not sure if I was helpful. -- mekeor ~ EDD3 DFFA 76F6 11C0 145F 9A99 AC85 BAD8 A2F8 C868