Nix 2.93.3
Lix: A modern, delicious implementation of the Nix package manager; unstable internal interfaces
Loading...
Searching...
No Matches
tarfile.hh
Go to the documentation of this file.
1#pragma once
3
5#include <archive.h>
6
7namespace nix {
8
9struct TarArchive {
10 struct archive * archive;
11 Source * source;
12 std::vector<unsigned char> buffer;
13
14 void check(int err, const std::string & reason = "failed to extract archive (%s)");
15
16 TarArchive(Source & source, bool raw = false);
17
18 TarArchive(const Path & path);
19
21 TarArchive(const TarArchive &) = delete;
22
23 void close();
24
25 ~TarArchive();
26};
27
28void unpackTarfile(Source & source, const Path & destDir);
29
30void unpackTarfile(const Path & tarFile, const Path & destDir);
31
32}
Definition serialise.hh:66
TarArchive(const TarArchive &)=delete
disable copy constructor
std::string Path
Definition types.hh:28