Commit graph

447 commits

Author SHA1 Message Date
Eelco Dolstra
24b3d0759e * File removed. 2003-04-24 11:41:50 +00:00
Eelco Dolstra
9713e8577f * getpkg, delpkg, and so on now accept multiple arguments. 2003-04-24 11:41:24 +00:00
Eelco Dolstra
49e0d743d7 * Fix descriptors for Pan and its dependencies. 2003-04-23 21:21:06 +00:00
Eelco Dolstra
f546e0cda4 * Fix descriptor for Subversion 0.21.0. 2003-04-23 09:02:53 +00:00
Eelco Dolstra
6faa154c89 * Add "... || exit 1" to every command to catch failure. 2003-04-23 07:23:01 +00:00
Eelco Dolstra
e59c3246b9 * Redirect stdout to stderr when executing the build script. 2003-04-23 07:21:57 +00:00
Eelco Dolstra
f7526febe4 * A garbage collector for installed packages. nix-collect-garbage
doesn't actually delete any packages, it just prints their
  descriptor hashes.  So we can do

    nix info $(nix-collect-garbage)

  to print out the ids of the packages that would be deleted, and

    nix delpkg $(nix-collect-garbage)

  to actually delete them.
2003-04-09 13:03:00 +00:00
Eelco Dolstra
30a6122f80 * When we activate a descriptor in nix-switch, remember its hash.
This allows us to find out all `live' packages on the system by
  doing

    nix closure $(cat /nix/var/nix/links/*.hash)

  which will print out the activated configurations and all packages
  referenced by them.  We could then garbage collect unused packages
  by deleting the difference between `nix listinst' and the set
  returned by `nix closure ...'.
2003-04-09 12:46:44 +00:00
Eelco Dolstra
b762f4df7f * In `fix --instantiate', only print out the hashes of the Nix
descriptors generated out of Fix descriptors specified on the
  command line.  This allows us to say:

    nix-switch $(fix -i ./test/fixdescriptors/system.fix)
2003-04-09 12:37:49 +00:00
Eelco Dolstra
aa8fda4b54 * We no longer use nix-populate standalone, rather we use it as a
build action for `system' packages (like system.fix) that have
  dependencies on all packages we want to activate.

  So the command sequence to switch to a new activation configuration
  of the system would be:

    $ fix -i .../fixdescriptors/system.fix
    ...
    system.fix -> 89cf4713b37cc66989304abeb9ea189f

    $ nix-switch 89cf4713b37cc66989304abeb9ea189f

* A nix-profile.sh script that can be included in .bashrc.
2003-04-09 12:26:48 +00:00
Eelco Dolstra
f56b7312b2 * Descriptor importing in Fix. 2003-04-08 15:36:54 +00:00
Eelco Dolstra
cc6eafb3d0 * FreeBSD / gcc 2.95 compatibility fixes.
* A script to generate prebuilt registration scripts.
2003-04-08 14:05:15 +00:00
Eelco Dolstra
f7ef88df1f * Added some installation instructions to the readme. 2003-04-08 12:13:57 +00:00
Eelco Dolstra
0d2b24cdd1 * `Fix' is a high-level descriptor instantiator for Nix. It replaces
nix-instantiate.
2003-04-08 12:00:51 +00:00
Eelco Dolstra
814b256da4 * Better installation: make directories, create database.
* Fixed the register script.
2003-04-06 22:19:26 +00:00
Eelco Dolstra
2eea8832f0 * The latest version of Pan. 2003-04-06 22:17:47 +00:00
Eelco Dolstra
1447cf35bd * Delete source after building. 2003-04-06 22:09:47 +00:00
Eelco Dolstra
136c00e881 * Autoconf / Automake configuration and building. 2003-04-04 16:14:56 +00:00
Eelco Dolstra
ab723e341a * Minor refactoring: use iterators to process arguments. 2003-04-04 12:02:40 +00:00
Eelco Dolstra
c68dca5dac * Script to register pre-built packages. 2003-04-02 15:34:44 +00:00
Eelco Dolstra
5bc26fb73f * Importing and exporting of pre-built packages. 2003-04-02 15:34:05 +00:00
Eelco Dolstra
383f9bb0f1 * Use ATerms for Nix descriptors. 2003-04-01 14:00:47 +00:00
Eelco Dolstra
ced20f187e * Nix descriptor for Subversion. 2003-03-31 14:28:15 +00:00
Eelco Dolstra
31f177ef0a * Check for collissions. 2003-03-28 16:27:23 +00:00
Eelco Dolstra
278ea4097e * Don't fork in `nix run'. 2003-03-28 10:33:34 +00:00
Eelco Dolstra
f915f77349 * Allow arguments to be passed to programs in `nix run'. 2003-03-28 09:53:22 +00:00
Eelco Dolstra
0f40a560ca * Added a script nix-activate which builds a list of "activated"
packages (i.e., the packages that should appear in the user's $PATH,
  and so on).  Based on this list, the script nix-populate creates a
  hierarchy of symlinks to the relevant files in those packages (e.g.,
  for pkg/bin and pkg/lib).  

  A nice property of nix-populate is that on each run it creates a
  *new* tree, rather than updating the old one.  It then atomically
  switches over to the new tree.  This allows atomic upgrades or
  rollbacks on the set of activated packages.
2003-03-25 16:36:25 +00:00
Eelco Dolstra
3f1a1457e9 * Integrate hash into instantiated descriptor file names.
* Use MD5::Digest.
2003-03-25 11:39:51 +00:00
Eelco Dolstra
73c53935d0 * For efficiency: md5 integrated into nix.
* Command `nix ensure' which is like `nix getpkg' except that if the
  has refers to a run action it will just ensure that the imports are
  there.
* Command `nix closure' to print out the closure of the set of
  descriptors under the import relation, starting at a set of roots.
  This can be used for garbage collection (e.g., given a list of
  `activated' packages, we can delete all packages not reachable from
  those).
* Command `nix graph' to print out a Dot graph of the dependency
  graph.
* `nix-addroot' adds a root for the (unimplemented) garbage collector.
2003-03-24 17:49:56 +00:00
Eelco Dolstra
eeab86e0ac * Typo fix. 2003-03-24 16:43:52 +00:00
Eelco Dolstra
2dc84e5569 * Descriptors now have a "system" field specifying the platform that
the build or run action should be perfomed on.  This ensures that
  descriptors have different hashes on different platforms.
2003-03-24 12:49:40 +00:00
Eelco Dolstra
9d2f128252 * Refactoring. 2003-03-24 11:50:20 +00:00
Eelco Dolstra
8d682ba551 * A descriptor for running the Pan newsreader.
* Added descriptors for gtkspell and its support package pspell.
  Gtkspell is an optional dependency of Pan, so we should add the
  ability to nix-instantiate to instantiate variants of a package
  based on a selection of features.
2003-03-23 23:28:28 +00:00
Eelco Dolstra
20d165c344 * A command to run programs in Nix packages, that is, to execute a run
action.  Run actions are described by uniquely hashed descriptors,
  just like build actions.  Therefore run actions can have
  dependencies, but these need not be the same as the build time
  dependencies (e.g., at runtime we can link against a different
  version of a dynamic library).  Example:

    nix run 31d6bf4c171282367065e0deecd7c579

  will run the Pan 0.13.91 newsreader with gtkspell support.
2003-03-23 23:24:09 +00:00
Eelco Dolstra
800d8e950f * Added a command to list installed packages. 2003-03-21 15:58:40 +00:00
Eelco Dolstra
2e59698b78 * Added a command to verify the consistency of the database. 2003-03-21 15:53:35 +00:00
Eelco Dolstra
fa51d6fcd9 * Forgot to commit this one. 2003-03-21 14:11:44 +00:00
Eelco Dolstra
e582ee67cd * Fetch sources from the network. 2003-03-21 14:10:06 +00:00
Eelco Dolstra
88d257b17f * Renamed dist -> build. 2003-03-21 09:58:01 +00:00
Eelco Dolstra
4c43711810 * Descriptor templates for the Pan newsreader and all its
dependencies.
2003-03-20 22:25:01 +00:00
Eelco Dolstra
cadc3852e4 * nix-instantiate now instantiantes the closure of the set of
descriptor templates under the import relation.  I.e., we can now
  say:

    nix-instantiate outdir foo.nix

  which will create descriptors for foo.nix and all imported packages
  in outdir/.
2003-03-20 22:23:48 +00:00
Eelco Dolstra
f7a98e081d * Various updates. 2003-03-20 16:53:00 +00:00
Eelco Dolstra
b3594e9eaf * A script to instantiate package descriptors from templates. 2003-03-20 16:52:30 +00:00
Eelco Dolstra
8999f923ea * Improved Nix. Resources (package descriptors and other source
files) are now referenced using their cryptographic hashes.  

  This ensures that if two package descriptors have the same contents,
  then they describe the same package.  This property is not as
  trivial as it sounds: generally import relations cause this property
  not to hold w.r.t. temporality.  But since imports also use hashes
  to reference other packages, equality follows by induction.
2003-03-14 16:43:14 +00:00
Eelco Dolstra
18ebf518de * Converted to C++. 2003-03-13 16:28:32 +00:00
Eelco Dolstra
75d788b0f2 * Initial version of nix. 2003-03-13 14:24:49 +00:00
Eelco Dolstra
841fcbd047 * And a trunk to go along with that. 2003-03-12 13:32:24 +00:00