#!@EMACS@ --script ;;; indent-code.el --- Run Emacs to indent a package definition. ;; Copyright © 2017 Alex Kost ;; Copyright © 2017 Ludovic Courtès ;; This file is part of GNU Guix. ;; GNU Guix is free software; you can redistribute it and/or modify ;; it under the terms of the GNU General Public License as published by ;; the Free Software Foundation, either version 3 of the License, or ;; (at your option) any later version. ;; GNU Guix is distributed in the hope that it will be useful, ;; but WITHOUT ANY WARRANTY; without even the implied warranty of ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ;; GNU General Public License for more details. ;; You should have received a copy of the GNU General Public License ;; along with this program. If not, see . ;;; Commentary: ;; This scripts indents the given file or package definition in the specified ;; file using Emacs. ;;; Code: ;; Load Scheme indentation rules from ".dir-locals.el". (with-temp-buffer (scheme-mode) (let ((default-directory (file-name-as-directory load-file-name)) (enable-local-variables :all)) (hack-dir-local-variables) (hack-local-variables-apply))) ;; Add indentation info for Scheme constructs that are not Guix-specific. ;; This is normally provided by Geiser but this file is for people who may not ;; be running Geiser, so we just copy it here (from 'geiser-syntax.el'). (defmacro guix-syntax--scheme-indent (&rest pairs) `(progn ,@(mapcar (lambda (p) `(put ',(car p) 'scheme-indent-function ',(cadr p))) pairs))) (guix-syntax--scheme-indent (and-let* 1) (case-lambda 0) (catch defun) (class defun) (dynamic-wind 0) (guard 1) (let*-values 1) (let-values 1) (let/ec 1) (letrec* 1) (match 1) (match-lambda 0) (match-lambda* 0) (match-let scheme-let-indent) (match-let* 1) (match-letrec 1) (opt-lambda 1) (parameterize 1) (parameterize* 1) (receive 2) (require-extension 0) (syntax-case 2) (test-approximate 1) (test-assert 1) (test-eq 1) (test-equal 1) (test-eqv 1) (test-group-with-cleanup 1) (test-runner-on-bad-count! 1) (test-runner-on-bad-end-name! 1) (test-runner-on-final! 1) (test-runner-on-group-begin! 1) (test-runner-on-group-end! 1) (test-runner-on-test-begin! 1) (test-runner-on-test-end! 1) (test-with-runner 1) (unless 1) (when 1) (while 1) (with-exception-handler 1) (with-syntax 1)) (pcase command-line-args-left (`(,file-name ,package-name) ;; Indent the definition of PACKAGE-NAME in FILE-NAME. (find-file file-name) (goto-char (point-min)) (if (re-search-forward (concat "^(define\\(-public\\) +" package-name) nil t) (let ((indent-tabs-mode nil)) (beginning-of-defun) (indent-sexp) (save-buffer) (message "Done!")) (error "Package '%s' not found in '%s'" package-name file-name))) (`(,file-name) ;; Indent all of FILE-NAME. (find-file file-name) (let ((indent-tabs-mode nil)) (indent-region (point-min) (point-max)) (save-buffer) (message "Done!"))) (x (error "Usage: indent-code.el FILE [PACKAGE]"))) ;;; indent-code.el ends here vail'>...* gnu/packages/bootstrap.scm (%bootstrap-inputs): Change to procedure. Update users; prepares for Mes bootstrap. * gnu/packages/commencement.scm (%boot0-inputs, %boot1-inputs, %boot2-inputs, %boot3-inputs, %boot4-inputs, %boot5-inputs, %boot-6-inputs): Change to procedure. Update users. * tests/builders.scm (%bootstrap-inputs, %bootstrap-search-paths): Make a procedure, filter on package?. Update users. Jan Nieuwenhuizen 2018-09-04Switch to Guile-Gcrypt....This removes (guix hash) and (guix pk-crypto), which now live as part of Guile-Gcrypt (version 0.1.0.) * guix/gcrypt.scm, guix/hash.scm, guix/pk-crypto.scm, tests/hash.scm, tests/pk-crypto.scm: Remove. * configure.ac: Test for Guile-Gcrypt. Remove LIBGCRYPT and LIBGCRYPT_LIBDIR assignments. * m4/guix.m4 (GUIX_ASSERT_LIBGCRYPT_USABLE): Remove. * README: Add Guile-Gcrypt to the dependencies; move libgcrypt as "required unless --disable-daemon". * doc/guix.texi (Requirements): Likewise. * gnu/packages/bash.scm, guix/derivations.scm, guix/docker.scm, guix/git.scm, guix/http-client.scm, guix/import/cpan.scm, guix/import/cran.scm, guix/import/crate.scm, guix/import/elpa.scm, guix/import/gnu.scm, guix/import/hackage.scm, guix/import/texlive.scm, guix/import/utils.scm, guix/nar.scm, guix/pki.scm, guix/scripts/archive.scm, guix/scripts/authenticate.scm, guix/scripts/download.scm, guix/scripts/hash.scm, guix/scripts/pack.scm, guix/scripts/publish.scm, guix/scripts/refresh.scm, guix/scripts/substitute.scm, guix/store.scm, guix/store/deduplication.scm, guix/tests.scm, tests/base32.scm, tests/builders.scm, tests/challenge.scm, tests/cpan.scm, tests/crate.scm, tests/derivations.scm, tests/gem.scm, tests/nar.scm, tests/opam.scm, tests/pki.scm, tests/publish.scm, tests/pypi.scm, tests/store-deduplication.scm, tests/store.scm, tests/substitute.scm: Adjust imports. * gnu/system/vm.scm: Likewise. (guile-sqlite3&co): Rename to... (gcrypt-sqlite3&co): ... this. Add GUILE-GCRYPT. (expression->derivation-in-linux-vm)[config]: Remove. (iso9660-image)[config]: Remove. (qemu-image)[config]: Remove. (system-docker-image)[config]: Remove. * guix/scripts/pack.scm: Adjust imports. (guile-sqlite3&co): Rename to... (gcrypt-sqlite3&co): ... this. Add GUILE-GCRYPT. (self-contained-tarball)[build]: Call 'make-config.scm' without #:libgcrypt argument. (squashfs-image)[libgcrypt]: Remove. [build]: Call 'make-config.scm' without #:libgcrypt. (docker-image)[config, json]: Remove. [build]: Add GUILE-GCRYPT to the extensions Remove (guix config) from the imported modules. * guix/self.scm (specification->package): Remove "libgcrypt", add "guile-gcrypt". (compiled-guix): Remove #:libgcrypt. [guile-gcrypt]: New variable. [dependencies]: Add it. [*core-modules*]: Remove #:libgcrypt from 'make-config.scm' call. Add #:extensions. [*config*]: Remove #:libgcrypt from 'make-config.scm' call. (%dependency-variables): Remove %libgcrypt. (make-config.scm): Remove #:libgcrypt. * build-aux/build-self.scm (guile-gcrypt): New variable. (make-config.scm): Remove #:libgcrypt. (build-program)[fake-gcrypt-hash]: New variable. Add (gcrypt hash) to the imported modules. Adjust load path assignments. * gnu/packages/package-management.scm (guix)[propagated-inputs]: Add GUILE-GCRYPT. [arguments]: In 'wrap-program' phase, add GUILE-GCRYPT to the search path. Ludovic Courtès