|
Nix 2.93.3
Lix: A modern, delicious implementation of the Nix package manager; unstable internal interfaces
|
#include "lix/libutil/async-io.hh"#include "lix/libutil/box_ptr.hh"#include "lix/libutil/generator.hh"#include "lix/libutil/types.hh"#include "lix/libutil/serialise.hh"#include "lix/libutil/file-system.hh"Go to the source code of this file.
Classes | |
| struct | nix::PreparedDump |
| struct | nix::NARParseVisitor |
| struct | nix::NARParseVisitor::FileHandle |
| struct | nix::nar::File |
| struct | nix::nar::Symlink |
| struct | nix::nar::Directory |
| struct | nix::nar_index::File |
| struct | nix::nar_index::Symlink |
| struct | nix::nar_index::Directory |
Typedefs | |
| using | nix::nar::Entry = std::variant<File, Symlink, Directory> |
| using | nix::nar_index::Entry = std::variant<File, Symlink, Directory> |
Functions | |
| WireFormatGenerator | nix::dumpPath (Path path, PathFilter &filter) |
| WireFormatGenerator | nix::dumpPath (Path path) |
| WireFormatGenerator | nix::dumpPathAndGetMtime (Path path, time_t &mtime) |
| box_ptr< PreparedDump > | nix::prepareDump (Path path) |
| box_ptr< PreparedDump > | nix::prepareDump (Path path, PathFilter &filter) |
| WireFormatGenerator | nix::dumpString (std::string_view s) |
| WireFormatGenerator | nix::nar::dump (Entry nar) |
| Generator< Entry > | nix::nar::parse (Source &source) |
| Entry | nix::nar_index::create (Source &source) |
| kj::Promise< Result< Entry > > | nix::nar_index::create (AsyncInputStream &source) |
| void | nix::parseDump (NARParseVisitor &sink, Source &source) |
| kj::Promise< Result< void > > | nix::parseDump (NARParseVisitor &sink, AsyncInputStream &source) |
| void | nix::restorePath (const Path &path, Source &source) |
| kj::Promise< Result< void > > | nix::restorePath (const Path &path, AsyncInputStream &source) |
| WireFormatGenerator | nix::copyNAR (Source &source) |
| box_ptr< AsyncInputStream > | nix::copyNAR (AsyncInputStream &source) |
Variables | |
| constexpr std::string_view | nix::narVersionMagic1 = "nix-archive-1" |
| constexpr std::string_view | nix::caseHackSuffix = "~nix~case~hack~" |
| WireFormatGenerator nix::copyNAR | ( | Source & | source | ) |
Read a NAR from 'source' and return it as a generator.
| WireFormatGenerator nix::dumpPath | ( | Path | path, |
| PathFilter & | filter ) |
dumpPath creates a Nix archive of the specified path.
| path | the file system data to dump. Dumping is recursive so if this is a directory we dump it and all its children. | |
| [out] | sink | The serialised archive is fed into this sink. |
| filter | Can be used to skip certain files. |
The format is as follows:
| WireFormatGenerator nix::dumpPathAndGetMtime | ( | Path | path, |
| time_t & | mtime ) |
Same as dumpPath(), but returns the last modified date of the path.
| WireFormatGenerator nix::dumpString | ( | std::string_view | s | ) |
Dump an archive with a single file with these contents.
| s | Contents of the file. |
| Generator< Entry > nix::nar::parse | ( | Source & | source | ) |
Parse a NAR from a source. The returned generator is guaranteed to produce only a single Entry but must be explicity read to exhaustion regardless to consume the entire nar from the source. Stopping before Generator::next() returns std::nullopt will not reading trailing metadata.