Commit Graph

348 Commits

Author SHA1 Message Date
Ludovic Courtès ab5d72ad2b doc: Document "guix pull --url".
* doc/guix.texi (Invoking guix pull): Add --url.
2013-10-13 01:14:21 +02:00
Ludovic Courtès b860f38244 Add (guix monads).
* guix/monads.scm: New file.
* tests/monads.scm: New file.
* Makefile.am (MODULES): Add guix/monads.scm.
  (SCM_TESTS): Add tests/monads.scm.
* doc/guix.texi (The Store Monad): New node.
  (The Store): Reference it.
2013-10-03 23:12:20 +02:00
Nikita Karetnikov ba7ea5ce33 doc: Fix typos.
* doc/guix.texi: Fix typos.
2013-09-27 08:22:02 +00:00
Ludovic Courtès 1bb9900a2a doc: Link from "guix gc" to '--delete-generations'.
* doc/guix.texi (Invoking guix package): Mention that deleting
  generations prevents roll-back.
  (Invoking guix gc): Link to '--delete-generations'.
2013-09-27 01:26:26 +02:00
Ludovic Courtès d7ddb257c9 guix package: '--delete-generations' deletes generations older than specified.
* guix/scripts/package.scm (matching-generations): Add
  'duration-relation' keyword parameter.
  (guix-package)[process-action](delete-generations): Pass
  #:duration-relation >.
* tests/guix-package.sh: Add test.
* doc/guix.texi (Invoking guix package): Clarify the meaning of
  durations for '--list-durations' and '--delete-durations'.
2013-09-27 01:23:59 +02:00
Nikita Karetnikov b7884ca3ca guix package: Add '--delete-generations'.
* guix/scripts/package.scm (switch-to-previous-generation): New function.
  (roll-back): Use the new function instead of 'switch-link'.
  (show-help): Add '--delete-generations'.
  (%options): Likewise.
  (guix-package)[process-actions]: Add 'current-generation-number',
  'display-and-delete', and 'delete-generation'.  Add support for
  '--delete-generations', and reindent the code.
* tests/guix-package.sh: Test '--delete-generations'.
* doc/guix.texi (Invoking guix-package): Document '--delete-generations'.
2013-09-26 15:41:43 +00:00
Nikita Karetnikov 4b2bc804d8 guix package: Do not list the zeroth generation.
* guix/scripts/package.scm (guix-package)[process-query]: Change
  'list-generation' to not list the zeroth generation.
* tests/guix-package.sh: Test it.
* doc/guix.texi (Invoking guix package): Document it, and use the
  right term when talking about generations.
2013-09-25 16:08:39 +00:00
Ludovic Courtès f566d765a1 doc: Document '--list-generations' among the query options.
* doc/guix.texi (Invoking guix package): Move '--list-generations' below
  "In addition to these actions".
2013-09-23 00:33:50 +02:00
Ludovic Courtès bd9bde1cba guix package: Show most recently installed packages last.
Suggested by Andreas Enge <andreas@enge.fr>.

* guix/scripts/package.scm (guix-package)[list-generations,
  list-installed]: Reverse the result of 'manifest-packages'.
* doc/guix.texi (Invoking guix package): Document the order of packages
  for '--list-generations' and '--list-installed'.
2013-09-23 00:33:50 +02:00
Nikita Karetnikov 2cd09108c9 guix package: Add '--list-generations'.
* guix/scripts/package.scm: Import (srfi srfi-19).
  (generation-time, matching-generations): New functions.
  (show-help): Add '--list-generations'.
  (%options): Likewise.
  (guix-package)[process-query]: Add support for '--list-generations'.
* guix/ui.scm: Import (srfi srfi-19) and (ice-9 regex).
  (string->generations, string->duration): New functions.
* tests/guix-package.sh: Test '--list-generations'.
* tests/ui.scm: Import (srfi srfi-19).
  Test 'string->generations' and 'string->duration'.
* doc/guix.texi (Invoking guix-package): Document '--list-generations'.
2013-09-19 11:22:31 +00:00
Ludovic Courtès 59688fc4b5 derivations: 'derivation' and related procedures return a single value.
* guix/derivations.scm (derivation->output-path,
  derivation->output-paths): New procedures.
  (derivation-path->output-path): Use 'derivation->output-path'.
  (derivation-path->output-paths): Use 'derivation->output-paths'.
  (derivation): Accept 'derivation?' objects as inputs.  Return a single
  value.
  (build-derivations): New procedure.
  (compiled-modules): Use 'derivation->output-paths'.
  (build-expression->derivation)[source-path]: Add case for when the
  input matches 'derivation?'.
  [prologue]: Accept 'derivation?' objects in INPUTS.
  [mod-dir, go-dir]: Use 'derivation->output-path'.
* guix/download.scm (url-fetch): Adjust to the single-value return.
* guix/packages.scm (package-output): Use 'derivation->output-path'.
* guix/scripts/build.scm (guix-build): When the argument is
  'derivation-path?', pass it through 'read-derivation'.
  Use 'derivation-file-name' to print out the .drv file names, and to
  register them.  Use 'derivation->output-path' instead of
  'derivation-path->output-path'.
* guix/scripts/package.scm (roll-back): Adjust to the single-value
  return.
  (guix-package): Use 'derivation->output-path'.
* guix/ui.scm (show-what-to-build): Adjust to deal with 'derivation?'
  objects instead of .drv file names.
* gnu/system/grub.scm (grub-configuration-file): Use
  'derivation->output-path' instead of 'derivation-path->output-path'.
* gnu/system/vm.scm (qemu-image, system-qemu-image): Likewise.
* tests/builders.scm, tests/derivations.scm, tests/packages.scm,
  tests/store.scm, tests/union.scm: Adjust to the new calling
  convention.
* doc/guix.texi (Defining Packages, The Store, Derivations): Adjust
  accordingly.
2013-09-18 18:49:53 +02:00
Ludovic Courtès cfbf916045 store: The 'references' parameter of 'add-text-to-store' is now optional.
* guix/store.scm (add-text-to-store): Make 'references' optional.
* tests/store.scm ("dead-paths", "references"): Use 'add-text-to-store'
  with no optional argument.
* doc/guix.texi (The Store): Adjust accordingly.
2013-09-11 01:07:49 +02:00
Andreas Enge c8c871d184 doc: Stylistic changes to "Packaging Guidelines" 2013-08-31 00:02:00 +02:00
Nikita Karetnikov a827c623ca doc: Remove an extra space after @ref. 2013-08-30 16:35:32 +00:00
Andreas Enge 46cb9da285 doc: Add duplicate copyright notice again.
* doc/guix.texi: Add second copyright notice again inside @ifinfo, needed
  since the first one does not appear in the info output.
  Partially undoes commit da7cabd.
2013-08-29 22:36:23 +02:00
Ludovic Courtès 29f66ddd7b doc: Fix the image size in PDF/PS/DVI output.
* doc/guix.texi (Bootstrapping): Specify an image width for the TeX
  output.  Before that, the image would be much wider than the US Letter
  page width.
2013-08-29 21:58:53 +02:00
Andreas Enge ee85f3dbe9 doc: Add package guidelines for names and numbers.
* doc/guix.texi: Three new subsections.
2013-08-28 22:51:20 +02:00
Andreas Enge da7cabd46b doc: Shuffle some text around.
* doc/guix.texi: Drop duplicate copyright notice, start section
    "Packaging Guidelines" with existant text.
2013-08-28 22:04:52 +02:00
Ludovic Courtès 858e92823f derivations: Rename #:dependency-graphs to #:references-graphs.
* guix/derivations.scm (derivation, build-expression->derivation):
  Rename #:dependency-graphs to #:references-graphs, for consistency in
  the terminology.
* tests/derivations.scm: Adjust accordingly.
2013-08-28 00:55:40 +02:00
Ludovic Courtès 9c629a27a4 derivations: Add #:dependency-graphs to `build-expression->derivation'.
* guix/derivations.scm (build-expression->derivation): Add
  #:dependency-graphs keyword argument.  Pass it to `derivation'.
* tests/derivations.scm ("build-expression->derivation with
  #:dependency-graphs"): New test.
* doc/guix.texi (Derivations): Update `build-expression->derivation'
  description.
2013-08-26 22:20:58 +02:00
Ludovic Courtès 5b0c9d1635 derivations: Add #:dependency-graphs `derivation' parameter.
* guix/derivations.scm (derivation): Add `dependency-graphs' keyword
  parameter; honor it.
* tests/derivations.scm (bootstrap-binary): New procedure.
  (%bash): Use it.
  (%mkdir): New variable.
  (directory-contents): Add `slurp' optional parameter.
  ("derivation with #:dependency-graphs"): New test.
* doc/guix.texi (Derivations): Update accordingly.
2013-08-26 22:20:53 +02:00
Ludovic Courtès a987d2c025 derivations: Move 3 positional parameters into keyword parameters.
* guix/derivations.scm (derivation): Turn `system', `env-vars', and
  `inputs' into keyword parameters.
  (build-expression->derivation): Adjust accordingly.
* gnu/packages/bootstrap.scm (%bootstrap-guile): Likewise.
* tests/derivations.scm, tests/store.scm: Likewise.
* doc/guix.texi (Derivations): Likewise.
2013-08-26 22:20:27 +02:00
Ludovic Courtès b095792f9b doc: Mention what's in the chroot, and add a caveat about /dev/shm.
* doc/guix.texi (Setting Up the Daemon): Document the default content of
  the chroot, and the /dev/shm caveat.
2013-08-24 17:30:31 +02:00
Ludovic Courtès b81e194706 doc: Add "Adding New Packages".
* doc/guix.texi (Adding New Packages): New section.
  (Packaging Guidelines): Make a subsection thereof.
  (From the Source Tarball to the Package): New subsection.
  (Contributing): Link to "Adding New Packages".
  (Package Modules): Link to modules in Guile's manual.
2013-07-17 11:59:48 +02:00
Ludovic Courtès 4a328f7342 doc: Mark 2.0.5 as being the minimum Guile version.
* doc/guix.texi (Requirements): Require Guile 2.0.5+.
* README: Ditto.
2013-07-17 11:01:42 +02:00
Ludovic Courtès 63f6004b95 doc: Refer to guix-devel@gnu.org.
* doc/guix.texi (Contributing): Refer to guix-devel@gnu.org.
2013-07-16 23:13:04 +02:00
Ludovic Courtès 91ef73d464 doc: Add "Installing Debugging Files".
* doc/guix.texi (Installing Debugging Files): New node.
  (Packages with Multiple Outputs): Add cross-reference.
2013-07-09 00:24:54 +02:00
Ludovic Courtès 6e721c4d02 doc: Add "Packages with Multiple Outputs" section.
* doc/guix.texi (Packages with Multiple Outputs): New node.
  (Invoking guix package): Refer to it.
2013-07-08 23:49:43 +02:00
Ludovic Courtès b208a00501 doc: Move the packaging guidelines to the manual.
* HACKING (Packaging Guidelines): Remove.
* doc/guix.texi (Packaging Guidelines): New node.
2013-07-07 23:26:31 +02:00
Ludovic Courtès 8b315a6dd5 doc: Add a "Porting" section.
* HACKING (Porting the Guix distro on a new platform): Remove.
* doc/guix.texi (Porting): New node.  Describe cross-compilation as the
  only approach.
2013-07-07 01:03:03 +02:00
Ludovic Courtès 401c53c469 doc: Add a "Boostrapping" section.
* doc/guix.texi (Package Modules): New node, with material formerly
  under "GNU Distribution".
  (Bootstrapping): New node.
* Makefile.am (EXTRA_DIST): Add doc/images/bootstrap-graph.dot and
  doc/images/bootstrap-graph.eps.
  (infoimagedir, dist_infoimage_DATA, DOT_OPTIONS): New variable.
  (.dot.png, .dot.eps, doc/guix.pdf, doc/guix.info, doc/guix.ps): New
  targets.
* doc/images/bootstrap-graph.dot: New file.
2013-07-07 00:29:50 +02:00
Ludovic Courtès 8e59fdd53b guix gc: Add `--requisites'.
* guix/scripts/gc.scm (show-help, %options): Add `--requisites'.
  (guix-gc): Handle it.
* doc/guix.texi (Invoking guix gc): Document `--requisites'.
* NEWS: Update.
2013-06-13 22:15:41 +02:00
Ludovic Courtès 9bf3c1a77d doc: Write about patch submission and packaging guidelines.
* HACKING: Update the command names from `guix-build' to `guix build' & co.
  (Submitting Patches, Packaging Guidelines): New sections.
* doc/guix.texi (Contributing): New section.
2013-06-04 10:29:57 +02:00
Ludovic Courtès 56b1f4b780 build, package: Add `--fallback' option.
* guix/scripts/build.scm (%options, show-help): Add `--fallback'.
  (guix-build): Call `set-build-options' with #:fallback?.
* guix/scripts/package.scm (%options, show-help): Add `--fallback'.
  (guix-package): Call `set-build-options' with #:fallback?.
* doc/guix.texi (Invoking guix package, Invoking guix build): Document
  `--fallback'.
2013-05-29 23:22:05 +02:00
Nikita Karetnikov 4bfc4ea349 doc: Improve wording and fix typos in "Introduction" and "Requirements".
* doc/guix.texi (Introduction, Requirements): Rephrase and fix typos.
2013-05-26 23:25:01 +00:00
Ludovic Courtès e55ec43d8b build: Add `--target' option.
* guix/scripts/build.scm (derivations-from-package-expressions): Add
  `package-derivation' parameter.
  (show-help, %options): Add `--target'.
  (guix-build): Use `package-cross-derivation' when `--target' is
  passed.
* tests/guix-build.sh: Add dry-run test with `--target'.
* doc/guix.texi (Invoking guix build): Document `--target'.
2013-05-24 22:52:52 +02:00
Ludovic Courtès 9c1edabd8b packages: Implement `package-cross-derivation'.
* guix/packages.scm (package-transitive-target-inputs,
  package-transitive-native-inputs): New procedures.
  (package-derivation): Parametrize `%current-target-system'.
  (package-cross-derivation): Implement.
* guix/utils.scm (%current-target-system): New variable.
* tests/packages.scm ("package-cross-derivation"): New test.
* doc/guix.texi (Defining Packages): Document
  `package-cross-derivation'.
2013-05-24 22:30:58 +02:00
Ludovic Courtès 969e678ed9 Add `--max-silent-time' to `guix build' and `guix package'.
* guix/scripts/build.scm (%default-options): Add default
  `max-silent-time' value.
  (show-help, %options):  Add `--max-silent-time'.
  (guix-build): Pass `max-silent-time' to `set-build-options'.
* guix/scripts/package.scm (%default-options): Add default
  `max-silent-time' value.
  (show-help, %options):  Add `--max-silent-time'.
  (guix-package): Pass `max-silent-time' to `set-build-options'.
* guix/ui.scm (string->number*): New procedure.
* tests/derivations.scm ("build-expression->derivation and
  max-silent-time"): New test.
* doc/guix.texi (Invoking guix package, Invoking guix build): Document
  `--max-silent-time'.
2013-05-20 18:29:26 +02:00
Ludovic Courtès 70c4329172 package: Make sure the profile directory is owned by the user.
* guix/scripts/package.scm (guix-package)[ensure-default-profile]: Check
  the owner of %PROFILE-DIRECTORY.  Report an error when the owner is
  not the current user.  Add `rtfm' procedure.
* doc/guix.texi (Invoking guix package): Mention the ownership test.
2013-05-16 20:04:13 +02:00
Ludovic Courtès 210cc92038 doc: Document "guix download".
* doc/guix.texi (Defining Packages): Linke to "Invoking guix download".
  (Utilities): Add an overview paragraph.
  (Invoking guix download): New node.
2013-05-11 16:18:15 +02:00
Ludovic Courtès f92300852f refresh: Add `--key-server' and `--gpg'.
* guix/scripts/refresh.scm (%options): Add `--key-server' and `--gpg'.
  (show-help): Update accordingly.
  (update-package): New procedure, formerly in `guix-refresh'.
  (guix-refresh): Use it.  Parameterize `%openpgp-key-server' and
  `%gpg-command'.
2013-05-11 14:36:58 +02:00
Ludovic Courtès 37166310c7 doc: Document `guix refresh'.
* doc/guix.texi (Defining Packages): Add cross-reference to "Invoking
  guix refresh".
  (Invoking guix refresh): New node.
2013-05-08 16:07:50 +02:00
Ludovic Courtès 5924080dcc guix package: Add `--search-paths' & co.
* guix/scripts/package.scm (search-path-environment-variables,
  display-search-paths): New procedures.
  (show-help, %options): Add `--search-paths'.
  (guix-package)[process-actions]: Call `display-search-paths' once the
  profile is ready.
  [process-query]: Honor `search-paths'.
2013-04-28 23:19:03 +02:00
Nikita Karetnikov 6c365eca6d Add 'guix hash'.
* guix/scripts/hash.scm: New file.
* Makefile.am (MODULES): Add it.
* po/POTFILES.in: Add it.
* doc/guix.texi (Invoking guix hash): New node.
  (Defining Packages): Add a cross-reference to the 'Invoking guix
  hash' node.
2013-04-21 19:22:14 +00:00
Ludovic Courtès 6858f9d132 daemon: Add `--no-substitutes'.
Suggested by Mark H. Weaver.

* nix/nix-daemon/guix-daemon.cc (GUIX_OPT_NO_SUBSTITUTES): New macro.
  (options): Add `--no-substitutes'.
  (parse_opt): Add `GUIX_OPT_NO_SUBSTITUTES' case.
  (main): Leave `settings.substituters' empty when
  `settings.useSubstitutes' is false.
2013-04-18 22:50:31 +02:00
Ludovic Courtès 48febeb81a doc: Mention the home page.
* doc/guix.texi (Installation): Add a sentence pointing to the home
  page.  Suggested by Arne Babenhauserheide.
2013-04-18 22:50:31 +02:00
Ludovic Courtès 3b78d1eab8 doc: Transparent binary deployment is implemented.
* doc/guix.texi (Features): Remove footnote saying that transparent
  binary deployment is not implemented.
2013-04-17 22:44:19 +02:00
Cyril Roelandt acb6ba2567 package: allow users to upgrade the whole system by not providing a regexp.
* guix/scripts/packages.scm (guix-package) [process-actions]: When upgrading,
use "" when REGEXP is #f.
* doc/guix.texi: update the documentation accordingly.
2013-04-16 23:12:29 +02:00
Ludovic Courtès 3b82460576 guix package: Add `--no-substitutes'.
* guix/scripts/package.scm (%default-options): Add `substitutes?'.
  (show-help, %options): Add and document `--no-substitutes'.
  (guix-package): Call `set-build-options' to honor `substitutes?'.
2013-04-12 17:31:05 +02:00
Ludovic Courtès ef010c0f3d guix package: Inform about new upstream versions of GNU packages.
* guix/gnu-maintenance.scm (gnu-package?): New procedure.
* guix/scripts/package.scm (waiting): New macro.
  (check-package-freshness): New procedure.
  (guix-package)[process-actions]: Use it.
* doc/guix.texi (Invoking guix package): Mention the feature.
2013-03-05 20:35:47 +01:00
Ludovic Courtès 5d4b411f8a guix package: Add `--install-from-expression'.
* guix/scripts/package.scm (read/eval-package-expression): New
  procedure.
  (show-help): Add `-e'.
  (%options): Likewise.
  (guix-package)[process-actions]: Handle ('install . p) pairs, where P
  is a package.
* tests/guix-package.sh: Add `boot_make_drv'.  Use `-i $boot_make_drv'
  once, and then use `-e $boot_make'.
* doc/guix.texi (Invoking guix package): Document `-e'.
2013-03-01 21:54:56 +01:00
Ludovic Courtès ba8b732d20 guix gc: Add `--references' and `--referrers'.
* guix/scripts/gc.scm (show-help): Update.
  (%options): Add `--references' and `--referrers'.
  (guix-gc)[symlink-target, store-directory]: New procedures.
  Handle the `list-references' and `list-referrers' actions.
* tests/guix-gc.sh: Add tests for `--references'.
* doc/guix.texi (Invoking guix gc): Document `--references' and
  `--referrers'.
2013-02-27 23:16:00 +01:00
Ludovic Courtès f651b477b7 Add "guix pull".
* guix/scripts/pull.scm: New file.
* Makefile.am (MODULES): Add it.
* doc/guix.texi (Invoking guix pull): New node.
  (Invoking guix package): Add cross-ref to it.
* guix/ui.scm (config-directory): New procedure.
* scripts/guix.in: When `GUIX_UNINSTALLED' is undefined, add
  $XDG_CONFIG_HOME/guix/latest to the search path.
* po/POTFILES.in: Add guix/scripts/pull.scm.
2013-02-20 23:47:16 +01:00
Ludovic Courtès 7730d112a2 build: Adjust guix.texi to Texinfo 5.0.
* doc/guix.texi: Change @title and @subtitle syntax to please Texinfo 5.0.
2013-02-20 23:46:52 +01:00
Ludovic Courtès b8d2aa264d daemon: Add `--listen'.
* nix/nix-daemon/guix-daemon.cc (GUIX_OPT_LISTEN): New macro.
  (options): Add `--listen'.
  (parse_opt): Handle it.
* doc/guix.texi (Invoking guix-daemon): Mention it.
2013-02-19 22:48:13 +01:00
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
Mark H Weaver dc5669cd65 Build newest versions unless specified, and implement upgrades.
* gnu/packages.scm (find-newest-available-packages):
  New exported procedure.

* guix-build.in (newest-available-packages, find-best-packages-by-name):
  New procedures.
  (find-package): Use find-best-packages-by-name, to guarantee that
  if a version number is not specified, only the newest versions will
  be considered.

* guix-package.in (%options): Add --upgrade/-u option.
  (newest-available-packages, find-best-packages-by-name, upgradeable?):
  New procedures.
  (find-package): Use find-best-packages-by-name, to guarantee that
  if a version number is not specified, only the newest versions will
  be considered.
  (process-actions): Implement upgrade option.

* doc/guix.texi (Invoking guix-package): In the description of --install,
  mention that if no version number is specified, the newest available
  version will be selected.
2013-02-13 22:05:19 -05:00
Ludovic Courtès 461572cca8 doc: Document installation of propagated inputs.
* doc/guix.texi (Invoking guix-package): Document installation behavior
  with propagated inputs.
2013-02-07 23:55:16 +01: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
Nikita Karetnikov acc084669c guix-package: Add '--search'.
* guix-package.in (find-packages-by-description): New procedure.
  (show-help, %options): Add '--search'.
  (guix-package)[process-query]: Add support for '--search'.
* doc/guix.texi (Invoking guix-package): Document it.
* tests/guix-package.sh: Add tests.
2013-01-28 06:47:49 +00:00
Ludovic Courtès 82fe08ed20 guix-package: Always use the next number for new generations.
Suggested by Andreas Enge <andreas@enge.fr> at
<http://lists.gnu.org/archive/html/bug-guix/2013-01/msg00325.html>.

* guix-package.in (latest-profile-number): Remove.
  (switch-symlinks): New procedure.
  (roll-back)[switch-link]: Use it.
  (guix-package)[process-actions]: Always choose NUMBER + 1 for the new
  profile.  Use `switch-symlinks' instead of `symlink'.  Remove code to
  delete PROFILE when it exists since `switch-symlinks' has the same
  effect.
* tests/guix-package.sh: Adjust existing `--roll-back' tests.
* doc/guix.texi (Invoking guix-package): Document this `--roll-back'
  behavior.
2013-01-27 17:58:46 +01:00
Ludovic Courtès d9307267b3 guix-package: When rolling back to nothingness, point to the empty profile.
Suggested by Andreas Enge <andreas@enge.fr> at
<http://lists.gnu.org/archive/html/bug-guix/2013-01/msg00316.html>.

* guix-package.in (roll-back): Check whether PROFILE is valid using
  `file-exists?'.  When NUMBER is zero, just emit a notice.  When
  PREVIOUS-NUMBER is zero and PREVIOUS-PROFILE does not exist, build the
  empty profile, and link to it.
* tests/guix-package.sh: Add tests.
* doc/guix.texi (Invoking guix-package): Document the new behavior.
2013-01-27 17:18:55 +01:00
Ludovic Courtès 6798a8e485 doc: Clarify that `guix-build' really is for developers.
* doc/guix.texi (Invoking guix-build): Make it clear that `guix-build'
  doesn't access the user's profile, and add cross-ref to `guix-package'.
  Suggested by Nikita Karetnikov <nikita@karetnikov.org>.
2013-01-23 23:33:09 +01:00
Ludovic Courtès 821b0015fa doc: Improve wording and fix typos in "Features".
* doc/guix.texi (Features): Fix typos, and rephrase according to the
  suggestions of Alex Sassmannshausen <alex.sassmannshausen@gmail.com>.
2013-01-23 15:40:13 +01:00
Ludovic Courtès 5401dd7595 guix-build: Allow version-qualified package names.
* guix-build.in (guix-build)[find-package]: New procedure.
  Use it instead of using `find-packages-by-name' directly.
  Suggested by Andreas Enge <andreas@enge.fr>.
* tests/guix-build.sh: Add tests.
* doc/guix.texi (Invoking guix-build): Add `coreutils-8.20' as an
  example.  Fix guile-1.8 example.
2013-01-22 22:14:25 +01:00
Ludovic Courtès e509d1527d packages: Have `package-derivation' return a <derivation> as a second value.
* guix/packages.scm (cache): Change the `drv' argument to `thunk'.
  Memoize all the return values of THUNK.
  (cached-derivation): Remove.
  (cached): New macro.
  (package-derivation): Use `cached' instead of `(or (cached-derivation) …)'.
* doc/guix.texi (Defining Packages): Update accordingly.
2013-01-20 22:54:36 +01:00
Ludovic Courtès 091196b383 doc: Run `useradd -g guix-builder -G guix-builder'.
* doc/guix.texi (Setting Up the Daemon): Add `-G guix-builder' when
  invoking `useradd'.
  Suggested by Aleix Conchillo Flaqué <aconchillo@gmail.com>.
2013-01-20 15:46:36 +01:00
Ludovic Courtès a1ba8475a6 doc: Add a "GNU Distribution" node.
* doc/guix.texi (Introduction): Add cross-reference to "GNU
  Distribution".
  (Features): Mention reproducibility.
  (Invoking guix-package): Add cross-reference to "GNU Distribution".
  (GNU Distribution): New node.
2013-01-18 01:29:24 +01:00
Ludovic Courtès 75f1e8f7cd doc: Mark binary deployment as not implemented yet.
* doc/guix.texi (Features): Add a footnote saying that binary deployment
  is missing.
2013-01-18 00:48:07 +01:00
Ludovic Courtès 24e262f086 guix-package: Add `--roll-back'.
Based on a patch by Nikita Karetnikov <nikita@karetnikov.org>.

* guix-package.in (profile-regexp): New procedure.
  (latest-profile-number): Remove `%profile-rx', and use
  `profile-regexp' instead.
  (profile-number, roll-back): New procedure.
  (show-help): Add `--roll-back'.
  (%options): Likewise.
  (guix-package)[process-actions]: First check whether `roll-back?' is
  among OPTS, and call `roll-back' if it is, followed by a recursive
  call to `process-actions'.  Emit the "nothing to be done" message only
  when INSTALL or REMOVE is non-empty.
* tests/guix-package.sh (readlink_base): New function.
  Add tests for `--roll-back'.
* doc/guix.texi (Invoking guix-package): Document `--roll-back'.
2013-01-17 22:42:39 +01:00
Ludovic Courtès 874e687428 doc: Start documenting derivations.
* doc/guix.texi (Defining Packages): Add cross-reference to
  "Derivations".
  (The Store): Add `build-derivations'.
  (Derivations): Populate.
2013-01-16 23:09:53 +01:00
Ludovic Courtès 1da983b9f0 doc: Fix typos, and improve daemon documentation.
* doc/guix.texi: Fix typos.
  (Invoking guix-daemon): Add details about `--disable-log-compression'
  and `--disable-store-optimization'.
  Reported by Nikita Karetnikov <nikita@karetnikov.org>.
2013-01-16 23:09:53 +01:00
Ludovic Courtès b28168c125 doc: Remove @documentlanguage.
* doc/guix.texi: Remove @documentlanguage, which confuses TeX.
2013-01-16 23:09:52 +01:00
Ludovic Courtès e531ac2ad9 doc: Start documenting (guix store).
* doc/guix.texi (The Store): Populate.
  (Introduction): Add cross-reference.  Change "package store" to "the
  store".
2013-01-15 23:32:13 +01:00
Ludovic Courtès 0ec1af59e5 guix-package: Create or diagnose missing profile directory.
Reported by Andreas Enge.

* guix-package.in (%profile-directory): Honor $NIX_STATE_DIR.
  (guix-package)[ensure-default-profile]: Use it.
  [process-actions]: Call it when the `profile' option is
  %CURRENT-PROFILE.
* tests/guix-package.sh: Add installation test with $HOME set, using the
  default profile.
2013-01-14 23:44:58 +01:00
Ludovic Courtès 80ba8cc076 doc: Fix typos.
* doc/guix.texi (Setting Up the Daemon): Use "useradd -c" for comments.
  Reported by Andreas Enge.
  (Invoking guix-gc): Fix typo.
2013-01-13 16:37:51 +01:00
Ludovic Courtès b22a12fda7 doc: Mention store sharing with Nix; update `package' example.
* doc/guix.texi: Set @documentlanguage.
  (Installation): Add reference to `INSTALL' and `README'.
  (Requirements): Mention store sharing with Nix.
  (Defining Packages): Update example to include `use-modules' clauses
  and to use (guix licenses).
2013-01-11 16:16:36 +01:00
Ludovic Courtès 01e354eb83 Merge branch 'core-updates'
Conflicts:
	guix/build/union.scm
2013-01-11 16:01:49 +01:00
Ludovic Courtès f03e7115d7 distro: libsigsegv: Use a single output.
* distro/packages/libsigsegv.scm (libsigsegv): Use just a single output,
  otherwise nothing ends up in `out' as a consequence of commit a06a99f.
  Reported by Andreas Enge <andreas@enge.fr>.
2013-01-10 22:33:35 +01:00
Ludovic Courtès bfe384cc4c doc: Clarify package version specification example.
* doc/guix.texi (Invoking guix-package): Use "guile-1.8.8" as the
  example, not "guile-1.8" since there is no such version.
2013-01-09 22:26:28 +01:00
Ludovic Courtès b9e5c0a949 guix-package: Create ~/.guix-profile when it doesn't exist.
* guix-package.in (guix-package): Create the %USER-ENVIRONMENT-DIRECTORY
  symlink if it doesn't exist yet.
* doc/guix.texi (Invoking guix-package): Document it.
2013-01-09 19:57:44 +01:00
Ludovic Courtès 44b6be7744 guix-package: Show package outputs in `--list-available'.
* guix-package.in (guix-package)[process-query]: For `list-available',
  show the outputs of each package.
* doc/guix.texi (Invoking guix-package): Update accordingly.
2013-01-09 19:26:37 +01:00
Ludovic Courtès 58db733e6d doc: Update copyright years; add visible copyright statement.
* doc/guix.texi (YEARS): New variable.
  Use it for all copyright statements.
  (Top): Add a copyright statement and license header here.
2013-01-09 13:01:48 +01:00
Ludovic Courtès bd5e766b87 doc: Documentation installation and the daemon.
* doc/guix.texi (Installation): New node.
2013-01-09 12:58:27 +01:00
Ludovic Courtès fe8ff02827 Add `guix-gc'.
* guix-gc.in, tests/guix-gc.sh: New files.
* configure.ac: Output `guix-gc', and make it executable.
* Makefile.am (bin_SCRIPTS): Add `guix-gc'.
  (TESTS): Add `tests/guix-gc.sh'.
* doc/guix.texi (Features): Add xref to "Invoking guix-gc".
  (Invoking guix-gc): New node.
* po/POTFILES.in: Add `guix-gc.in'.
2013-01-06 00:28:06 +01:00
Ludovic Courtès 07ab4bf1fc guix-build: Add `--verbosity'.
* guix-build.in (%default-options): Add `verbosity'.
  (%options): Add `--verbosity'.
  (guix-build): Pass it to `set-build-options'.
  (show-help): Update accordingly.
* doc/guix.texi (Invoking guix-build): Document `--verbosity'.
2012-12-15 15:21:38 +01:00
Ludovic Courtès 70915c1a2e guix-package: Add `--verbose'; silence the environment's build by default.
* guix-package.in (%options): Add `--verbose'.
  (show-help): Update accordingly.
  (guix-package): Parameterize `current-build-output-port' according to
  VERBOSE?.  By default, silence the environment build's output.
2012-12-12 14:59:16 +01:00
Ludovic Courtès ba55b1cb69 doc: Fix typos.
* doc/guix.texi: Fix typos.  Reported by Andreas Enge <andreas@enge.fr>.
2012-12-12 14:46:43 +01:00
Ludovic Courtès 51c8d7909d doc: Correct short name of `--install' option of `guix-package'.
* doc/guix.texi (Invoking guix-package): Fix short form of `--install'.
  Reported by Andreas Enge <andreas@enge.fr>.
2012-12-09 23:35:03 +01:00
Ludovic Courtès c80e7e55b3 doc: Mention the pronunciation of "Guix".
* README: Mention pronunciation of "Guix".
* doc/guix.texi (Introduction): Likewise.
2012-11-25 16:08:10 +01:00
Ludovic Courtès 3dc1970dda doc: Document basic package definitions.
* doc/guix.texi (Programming Interface): Add introduction.
  (Defining Packages): Populate.
2012-11-21 15:56:43 +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 733b4130d7 guix-package: Add `--list-installed'.
* guix-package.in (show-help, %options): Add `--list-installed'.
  (guix-package): Move main body to...
  [process-actions]: ... here.  New internal procedure.
  [process-query]: New procedure.
* tests/guix-package.sh: Add tests for `--list-installed'.
* doc/guix.texi (Invoking guix-package): Document it.
2012-11-19 23:04:35 +01:00
Ludovic Courtès f8348b91ad Turn Guix into "GNU Guix".
* configure.ac: Change package name to "GNU Guix", and bug-report
  address to `gnu-system-discuss@gnu.org'.
* doc/guix.texi: Replace "Guix" by "GNU Guix" in some places.
  (Top, Introduction): Mention "for the GNU system".
* HACKING, README: Use "GNU Guix" instead of "Guix" in some places.
2012-11-18 15:22:00 +01:00
Ludovic Courtès eeaf44276c doc: Document the features and `guix-package'.
* doc/guix.texi: Change the category to "Package management".  Add an
  @direntry for "Invoking guix-package".
  (Package Management): New chapter.
2012-11-07 19:27:42 +01:00
Ludovic Courtès c78bd12b44 doc: Document `guix-build'.
* doc/guix.texi (Invoking guix-build): Populate.
2012-11-07 17:07:15 +01:00
Ludovic Courtès d3c9a1dae8 doc: Remove unnecessary @ifinfo.
* doc/guix.texi: Remove @ifinfo around @dir{category,entry}.  Suggested
  by Karl Berry <karl@freefriends.org>.
2012-11-07 16:45:11 +01:00
Ludovic Courtès 568717fd90 doc: Add the stub of a manual.
* doc/guix.texi: New file.
* doc/fdl-1.3.texi: New file, copied from Gnulib.

* Makefile.am (info_TEXINFOS): New variable.
  (EXTRA_DIST): Add `doc/fdl-1.3.texi'.
2012-10-13 16:05:01 +02:00