about summary refs log tree commit diff
path: root/src/libutil/archive.hh
AgeCommit message (Collapse)AuthorFilesLines
2018-05-30 Modularize config settingsEelco Dolstra1-4/+0
Allow global config settings to be defined in multiple Config classes. For example, this means that libutil can have settings and evaluator settings can be moved out of libstore. The Config classes are registered in a new GlobalConfig class to which config files etc. are applied. Relevant to https://github.com/NixOS/nix/issues/2009 in that it removes the need for ad hoc handling of useCaseHack, which was the underlying cause of that issue.
2018-03-21 Make 'nix copy --from ssh://...' run in constant memoryEelco Dolstra1-0/+3
For instance, this reduced the memory consumption of $ nix copy --from ssh://localhost --to ~/my-nix /nix/store/1n7x0yv8vq6zi90hfmian84vdhd04bgp-blender-2.79a from 632 MiB to 16 MiB.
2017-10-30 builtins.fetchgit: Support importing a working treeEelco Dolstra1-7/+0
For example, you can write src = fetchgit ./.; and if ./. refers to an unclean working tree, that tree will be copied to the Nix store. This removes the need for "cleanSource".
2017-03-06 Revert fa125b9b28bea25a4eeb4d39a71a481563127cb9Eelco Dolstra1-6/+0
This causes quadratic performance.
2017-03-01 TeeSink: Pre-reserve string spaceEelco Dolstra1-0/+13
When receiving a very large file, this can prevent the string from having tobe copied, which temporarily doubles memory consumption.
2016-02-25 Add NAR / Store accessor abstractionEelco Dolstra1-0/+1
This is primary to allow hydra-queue-runner to extract files like "nix-support/hydra-build-products" from NARs in binary caches.
2016-02-24 BinaryCacheStore: Implement addToStore()Eelco Dolstra1-0/+5
So now you can do $ NIX_REMOTE=file:///tmp/binary-cache nix-instantiate '<nixpkgs>' -A hello and lots of other operations.
2014-07-16 Handle case collisions on case-insensitive systemsEelco Dolstra1-4/+8
When running NixOps under Mac OS X, we need to be able to import store paths built on Linux into the local Nix store. However, HFS+ is usually case-insensitive, so if there are directories with file names that differ only in case, then importing will fail. The solution is to add a suffix ("~nix~case~hack~<integer>") to colliding files. For instance, if we have a directory containing xt_CONNMARK.h and xt_connmark.h, then the latter will be renamed to "xt_connmark.h~nix~case~hack~1". If a store path is dumped as a NAR, the suffixes are removed. Thus, importing and exporting via a case-insensitive Nix store is round-tripping. So when NixOps calls nix-copy-closure to copy the path to a Linux machine, you get the original file names back. Closes #119.
2012-07-18 Use "#pragma once" to prevent repeated header file inclusionEelco Dolstra1-5/+1
2010-05-04 * Revert r15436. This was a workaround for a bug in btrfs which seemsEelco Dolstra1-1/+0
to have been fixed now.
2009-05-04 Add an ftruncate call paired with fallocate to play safe with some FSes ↵Michael Raskin1-0/+1
(namely, BtrFS fallocate sets file size to allocated size, i.e. multiple of block size)
2009-03-22 * NAR archives: handle files larger than 2^32 bytes. Previously itEelco Dolstra1-0/+1
would just silently store only (fileSize % 2^32) bytes. * Use posix_fallocate if available when unpacking archives. * Provide a better error message when trying to unpack something that isn't a NAR archive.
2008-12-03 * A simple API for parsing NAR archives.Eelco Dolstra1-0/+13
2006-12-12 * New primop builtins.filterSource, which can be used to filter filesEelco Dolstra1-4/+4
from a source directory. All files for which a predicate function returns true are copied to the store. Typical example is to leave out the .svn directory: stdenv.mkDerivation { ... src = builtins.filterSource (path: baseNameOf (toString path) != ".svn") ./source-dir; # as opposed to # src = ./source-dir; } This is important because the .svn directory influences the hash in a rather unpredictable and variable way.
2006-12-12 * In dumpPath(): pass a function object that allows files to beEelco Dolstra1-1/+10
selectively in/excluded from the dump.
2006-11-30 * Skeleton of the privileged worker program.Eelco Dolstra1-20/+3
* Some refactoring: put the NAR archive integer/string serialisation code in a separate file so it can be reused by the worker protocol implementation.
2006-09-04 * Use a proper namespace.Eelco Dolstra1-2/+12
* Optimise header file usage a bit. * Compile the parser as C++.
2005-03-03 * Don't use fork() in copyPath(), but a string buffer.Eelco Dolstra1-0/+3
2003-11-18 * Source tree refactoring.Eelco Dolstra1-0/+60