Commit graph

44 commits

Author SHA1 Message Date
Eelco Dolstra 9d2669d218 * Added a utility that can be used to produce nice HTML pages from Nix
build logs.  The program `log2xml' converts a Nix build log (read
  from standard input) into XML file that can then be converted to
  XHTML by the `log2html.xsl' stylesheet.  The CSS stylesheet
  `logfile.css' is necessary to make it look good.

  This is primarily useful if the log file has a *tree structure*,
  i.e., that sub-tasks such as the various phases of a build (unpack,
  configure, make, etc.) or recursive invocations of Make are
  represented as such.  While a log file is in principle an
  unstructured plain text file, builders can communicate this tree
  structure to `log2xml' by using escape sequences:

  - "\e[p" starts a new nesting level; the first line following the
    escape code is the header;

  - "\e[q" ends the current nesting level.

  The generic builder in nixpkgs (not yet committed) uses this.  It
  shouldn't be to hard to patch GNU Make to speak this protocol.

  Further improvements to the generated HTML pages are to allow
  collapsing/expanding of subtrees, and to abbreviate store paths (but
  to show the full path by hovering the mouse over it).
2004-03-15 21:51:14 +00:00
Eelco Dolstra 9898746ef3 * nix-env: a tool to manage user environments.
* Replace all directory reading code by a generic readDirectory()
  function.
2003-11-19 17:27:16 +00:00
Eelco Dolstra fd7ac09f10 * Refactoring (step 2). 2003-11-19 12:03:01 +00:00
Eelco Dolstra ac68840e79 * Refactoring: put the Nix expression evaluator in its own library so
that it can be used by multiple programs.
2003-11-19 11:35:41 +00:00
Eelco Dolstra dfc9c64ead * "Fix expression" -> "Nix expression".
* More refactoring.
2003-11-18 12:06:07 +00:00
Eelco Dolstra b1117ef29d * nix -> nix-store, fix -> nix-instantiate. 2003-11-18 11:38:25 +00:00
Eelco Dolstra 9f0f020929 * libnix -> libstore. 2003-11-18 10:55:27 +00:00
Eelco Dolstra 8798fae304 * Source tree refactoring. 2003-11-18 10:47:59 +00:00
Eelco Dolstra 4d728f6a36 * Forked new version of Fix. 2003-10-29 15:05:18 +00:00
Eelco Dolstra c62433751d * Finished refactoring the tree. 2003-10-20 10:05:01 +00:00
Eelco Dolstra 5d4171f7fb * Synchronise terminology with the ICSE paper (e.g., slice -> closure,
fstate -> Nix expression).
* Fix src/test.cc.
2003-10-07 12:27:49 +00:00
Eelco Dolstra e78f753aa8 * Include the right files in a distribution. 2003-10-02 12:22:19 +00:00
Eelco Dolstra 1c7d6bf5fc * Removed references to char_traits so that boost/format also works on
GCC 2.95.
2003-09-11 10:23:55 +00:00
Eelco Dolstra c0bbed0959 * Factored out dot graph generation into a separate file. 2003-09-03 11:20:18 +00:00
Eelco Dolstra 545145cd58 * normaliseFState() now locks all output paths prior to building, thus
ensuring that simultaneous invocations of Nix don't clobber
  each other's  builds.

* Fixed a bug in `make install'.
2003-08-01 14:11:19 +00:00
Eelco Dolstra 4a013962bd * Started using Berkeley DB environments. This is necessary for
transaction support (but we don't actually use transactions yet).
2003-07-31 13:47:13 +00:00
Eelco Dolstra 8846465934 * Get garbage collection and cache population to work *properly*.
Renamed `fstateRefs' to `fstateRequisites'.  The semantics of this
  function is that it returns a list of all paths necessary to realise
  a given expression.  For a derive expression, this is the union of
  requisites of the inputs; for a slice expression, it is the path of
  each element in the slice.  Also included are the paths of the
  expressions themselves.  Optionally, one can also include the
  requisites of successor expressions (to recycle intermediate
  results).

* `nix-switch' now distinguishes between an expression and its normal
  form.  Usually, only the normal form is registered as a root of the
  garbage collector.  With the `--source-root' flag, it will also
  register the original expression as a root.

* `nix-collect-garbage' now has a flag `--keep-successors' which
  causes successors not to be included in the list of garbage paths.

* `nix-collect-garbage' now has a flag `--invert' which will print all
  paths that should *not* be garbage collected.
2003-07-29 14:28:17 +00:00
Eelco Dolstra 949c4fa1a8 * `nix --help'.
* `nix --query --graph' to print a dot dependency graph of derive
  expressions.
2003-07-28 12:19:23 +00:00
Eelco Dolstra 39ce70025b * Incorporated Berkeley DB and ATerm into the source tree.
* `make dist'.
2003-07-23 15:53:34 +00:00
Eelco Dolstra 9202570f8c * libdb_cxx-4 -> libdb_cxx 2003-07-22 20:02:33 +00:00
Eelco Dolstra 6f1a0f948d * Refactorings. 2003-07-20 19:29:38 +00:00
Eelco Dolstra 3509299aca * After building, scan for actual file system references as
opposed to declared references.  This prunes the reference
  graph, thus allowing better garbage collection and more
  efficient derivate distribution.
2003-07-14 10:23:11 +00:00
Eelco Dolstra e6363b05ae * Pass $(prefix) and other variables through -D..., not
through config.h, to prevent silly Autoconf problems.
2003-07-13 19:26:00 +00:00
Eelco Dolstra 9c620e4afa * Generate the scripts so that we can substitute the prefix
etc. correctly.
* Fixed nix-switch.
2003-07-13 18:58:03 +00:00
Eelco Dolstra 5895c160c4 * Make dbRefs a mapping from Hash to [Path]. 2003-07-07 09:25:26 +00:00
Eelco Dolstra 224c585aba * Refactoring on the file names. 2003-07-07 07:43:58 +00:00
Eelco Dolstra 7952a8053c * A utility `nix-hash' to compute Nix path hashes. 2003-07-06 15:11:02 +00:00
Eelco Dolstra 82e3d8fafe * Got Fix working again. 2003-07-06 14:20:47 +00:00
Eelco Dolstra f826e432aa * Refactoring: move initialisation and argument parsing into a shared
file.
2003-07-04 15:42:03 +00:00
Eelco Dolstra 207ff2caf0 * Caching of expression successors. 2003-07-04 12:18:06 +00:00
Eelco Dolstra 2b07b0e7eb * Minor cleanups. 2003-06-25 14:58:56 +00:00
Eelco Dolstra 5079ccb455 * Move most of Nix into a library (libnix.a).
* Run `test' on `make check'.
2003-06-20 10:53:04 +00:00
Eelco Dolstra 1849aa2a72 * Refactoring: move dump function into archive.cc. 2003-06-20 10:40:25 +00:00
Eelco Dolstra fab7b128b9 * Automake sucks. 2003-06-18 08:07:28 +00:00
Eelco Dolstra 34fcf5fa0c * Started integrating the new evaluation model into Nix.
* Cleaned up command-line syntax.
2003-06-17 21:12:58 +00:00
Eelco Dolstra 822794001c * Started implementing the new evaluation model.
* Lots of refactorings.
* Unit tests.
2003-06-16 13:33:38 +00:00
Eelco Dolstra 21fe717ce2 * Refactoring: hash class. 2003-06-15 13:41:32 +00:00
Eelco Dolstra d1f5fd7216 * Log the output of builders to $prefix/var/log/nix. 2003-05-30 15:21:52 +00:00
Eelco Dolstra 8b930a0c94 * Some refactoring. 2003-05-26 13:45:00 +00:00
Eelco Dolstra 7dd91d3779 * Prebuilt package sharing. We allow transparent binary deployment by
sharing package directories (i.e., the result of building a Nix
  descriptor).

  `nix-pull-prebuilts' obtains a list of all known prebuilts by
  consulting the paths and URLs specified in
  $prefix/etc/nix/prebuilts.conf.  The mappings ($pkghash,
  $prebuilthash) and ($prebuilthash, $location) are registered with
  Nix so that it can use the prebuilt with hash $prebuilthash when
  installing a package with hash $pkghash by downloading and unpacking
  $location.

  `nix-push-prebuilts' creates prebuilts for all packages for which no
  prebuilt is known to exist.  It can then optionally upload these
  to the network through rsync.

  `nix-[pull|push]-prebuilts' just provide a policy.  Nix provides the
  mechanism through the `nix [export|regprebuilt|regurl]' commands.
2003-05-25 22:42:19 +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 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 136c00e881 * Autoconf / Automake configuration and building. 2003-04-04 16:14:56 +00:00