Commit Graph

8 Commits (a24b75d8e1753da629ecf945f4022eee4c340aed)

Author SHA1 Message Date
Mark H Weaver e49951eb3e Replace individual scripts with master 'guix' script.
* scripts/guix.in: New script.

* Makefile.am (bin_SCRIPTS): Add 'scripts/guix'.  Remove 'guix-build',
  'guix-download', 'guix-import', 'guix-package', and 'guix-gc'.

  (MODULES): Add 'guix/scripts/build.scm', 'guix/scripts/download.scm',
  'guix/scripts/import.scm', 'guix/scripts/package.scm', and
  'guix/scripts/gc.scm'.

* configure.ac (AC_CONFIG_FILES): Add 'scripts/guix'.  Remove 'guix-build',
  'guix-download', 'guix-import', 'guix-package', and 'guix-gc'.

* guix-build.in, guix-download.in, guix-gc.in, guix-import.in,
  guix-package.in: Remove shell script boilerplate.  Move to guix-COMMAND.in
  to guix/scripts/COMMAND.scm.  Rename module from (guix-COMMAND) to
  (guix scripts COMMAND).  Change "guix-COMMAND" to "guix COMMAND" in
  usage help string.

* pre-inst-env.in: Add "@abs_top_builddir@/scripts" to the front of $PATH.
  Export $GUIX_UNINSTALLED.

* tests/guix-build.sh, tests/guix-daemon.sh, tests/guix-download.sh,
  tests/guix-gc.sh, tests/guix-package.sh: Use "guix COMMAND" instead of
  "guix-COMMAND".

* doc/guix.texi: Replace all occurrences of "guix-COMMAND" with
  "guix COMMAND".

* po/POTFILES.in: Update.
2013-02-16 22:17:37 -05:00
Ludovic Courtès 299112d36e guix-package: Report `--search' matches in recutils format.
* guix/ui.scm (fill-paragraph, string->recutils, package->recutils): New
  procedures.
* guix-package.in (guix-package)[process-query]: Use `package->recutils'
  to display package meta-data.
* tests/guix-package.sh: Adjust test.
* tests/ui.scm: New file.
* Makefile.am (TESTS): Add it.
* doc/guix.texi (Invoking guix-package): Adjust `--search'
  documentation, and give an example.
2013-02-01 13:16:41 +01:00
Ludovic Courtès 473b03b3c6 Gracefully handle failure to install the current locale.
* guix/ui.scm (install-locale): New procedure.
* guix-build.in, guix-download.in, guix-gc.in, guix-import.in,
  guix-package.in: Use it instead of (setlocale LC_ALL "").
2013-01-30 00:09:32 +01:00
Ludovic Courtès 233e76769a Update license headers.
Change all license headers, except guix/build/* and ld-wrapper.scm, with
this code:

  (use-modules (guix build utils)
	       (srfi srfi-1))

  (fluid-set! %default-port-encoding "UTF-8")

  (substitute* (remove (lambda (f)
			 (or (string-contains f ".tar.")
			     (string-contains f ".git/")
			     (string-contains f ".so")
			     (string-suffix? ".o" f)
			     (string-suffix? ".a" f)
			     (string-suffix? ".go" f)
			     (string-suffix? ".pdf" f)
			     (string-suffix? ".png" f)
			     (string-suffix? ".info" f)
			     (equal? (basename f) "guix-daemon")
			     (equal? (basename f) "nix-setuid-helper")
			     (string-contains f "nix-upstream/")
			     (string-contains f "distro/packages/bootstrap/")))
		       (find-files "." "\\.[a-z]+$"))
    (("^([[:graph:]]+) This file is part of Guix." _ comment-start)
     (string-append comment-start " This file is part of GNU Guix."))
    (("^([[:graph:]]+) Guix --- Nix package management.*" _ comment-start)
     (string-append comment-start
		    " GNU Guix --- Functional package management for GNU\n"))
    (("^([[:graph:]]+) Guix is " _ comment-start)
     (string-append comment-start " GNU Guix is "))
    (("^([[:graph:]]+) along with Guix." _ comment-start)
     (string-append comment-start " along with GNU Guix."))
    (("^([[:graph:]]+) Copyright \\(C\\)" _ comment-start)
     (string-append comment-start " Copyright ©")))

Change headers using C-style comments manually.
2013-01-06 00:47:50 +01:00
Ludovic Courtès 3441e16497 ui: Factorize bug-report information in `--help'.
* guix/config.scm.in (%guix-home-page-url): New variable.
* guix/ui.scm (show-bug-report-information): New procedure.
* guix-build.in (show-help): Use it.
* guix-download.in (show-help): Likewise.
* guix-import.in (show-help): Likewise.
* guix-package.in (show-help): Likewise.
2013-01-05 15:55:47 +01:00
Ludovic Courtès 64fc89b6ec guix-package: Add `--list-available'.
* guix-package.in (show-help, %options): Add `--list-available'.
  (guix-package)[process-query]: Add support for `--list-available'.
* doc/guix.texi (Invoking guix-package): Document it.
* tests/guix-package.sh: Add test.

* guix/ui.scm (location->string): New procedure.
* guix/utils.scm: Export <location>.
2012-11-19 23:04:38 +01:00
Ludovic Courtès cdd5d6f95f ui: Factorize `--version'.
* guix/ui.scm (show-version-and-exit): New procedure.
* guix-build.in (show-version): Remove.
  (%options)["version"]: Use `show-version-and-exit'.
* guix-download.in: Likewise.
* guix-package.in: Likewise.
2012-11-03 21:19:43 +01:00
Ludovic Courtès 073c34d72f Add (guix ui).
* guix/ui.scm: New file.
* Makefile.am (MODULES): Add it.
* po/POTFILES.in: Add it.

* guix-build.in: Use it.
  (_, N_, leave): Remove.
  (guix-build): Use `with-error-handling' instead of the `guard' form.
* guix-download.in: Use it.
  (_, N_, leave): Remove.
2012-11-01 00:52:44 +01:00