Ben Burdette
47ed067d45
initializer style
2020-04-08 09:07:58 -06:00
Ben Burdette
00c507cc52
columnRange -> column
2020-04-07 14:36:32 -06:00
Ben Burdette
55c96b64e4
comment cleanup
2020-04-06 20:14:48 -06:00
Ben Burdette
ec449c8450
constructor style basically working
2020-04-06 19:43:22 -06:00
Ben Burdette
216263c36f
Merge branch 'master' into error-format
2020-04-06 10:00:00 -06:00
Ben Burdette
9bb528d392
handle Pos instead of individual file/line/columnrange args
2020-04-03 13:15:59 -06:00
Ben Burdette
7b7801d3f0
variadic args for hint format
2020-04-03 08:48:20 -06:00
Ben Burdette
c6b3fcddb0
formatted with astyle
2020-04-02 16:02:40 -06:00
Ben Burdette
1c329ca433
indenting
2020-04-02 14:25:43 -06:00
Ben Burdette
e697884f65
using std:: everywhere; fix a formatting error; add exception flags
2020-04-01 21:30:19 -06:00
Ben Burdette
dd7b8183a5
indenting
2020-04-01 16:20:20 -06:00
Ben Burdette
8713aeac5e
remove using std::*, switch to include guard
2020-04-01 15:51:14 -06:00
Ben Burdette
5b3aefff85
add some explanatory comments
2020-03-31 12:42:41 -06:00
Ben Burdette
9e7b89bf10
rename errors/warnings
2020-03-31 11:56:37 -06:00
Ben Burdette
09652f597c
enum style
2020-03-31 09:36:20 -06:00
Eelco Dolstra
e1a94ad852
Backport 'nix dev-shell' from the flakes branch
...
This also adds a '--profile' option to 'nix build' (replacing 'nix-env
--set').
2020-03-30 19:16:45 +02:00
Ben Burdette
35c7bab09a
build with make
2020-03-30 09:14:29 -06:00
Ben Burdette
759f39800b
remove util.hh from deps
2020-03-27 10:55:09 -06:00
Ben Burdette
00eb3fcb7a
more cleanup
2020-03-27 10:13:46 -06:00
Ben Burdette
a3ef00be6c
camelcase; optional hint
2020-03-27 10:03:02 -06:00
Ben Burdette
d44c9c5581
some colors
2020-03-25 11:20:44 -06:00
Ben Burdette
3582dc3c88
programName as static member var
2020-03-25 10:52:03 -06:00
Ben Burdette
fc310eda3a
switch to one level of builder function, not subobject functions
2020-03-24 14:24:57 -06:00
Ben Burdette
0166e7ab6d
MkNixCode, MkErrLine approach
2020-03-24 11:21:35 -06:00
Ben Burdette
4171ab4bbd
renaming
2020-03-24 09:18:23 -06:00
Eelco Dolstra
0a10854f85
Misc changes from the flakes branch
2020-03-24 14:34:47 +01:00
Eelco Dolstra
7a8de57d3e
Pretty-print 'nix why-depends' / 'nix-store -q --tree' output
...
Extracted from 678301072f
.
2020-03-24 14:26:23 +01:00
Eelco Dolstra
4260a22a55
absPath(): Use std::optional
...
(cherry picked from commit 1bf9eb21b7
)
2020-03-24 14:25:28 +01:00
Eelco Dolstra
edc34cc1a2
Add function for quoting strings
...
(cherry picked from commit 7dcf5b011a
)
2020-03-24 13:44:04 +01:00
Ben Burdette
aadd59d005
error test
2020-03-23 15:29:49 -06:00
Ben Burdette
f694f43d7d
straightforward port of rust mockup code
2020-03-22 12:25:47 -06:00
Eelco Dolstra
d8972317fc
Prevent uninitialized StorePath creation
2020-02-13 16:12:16 +01:00
Eelco Dolstra
c5319e5d0b
Show "warning:" in yellow instead of red
2020-02-01 12:37:22 +01:00
Eelco Dolstra
c84c843e33
tarfile.cc: Restore timestamps
...
This is needed to get the lastModified attribute of GitHub flakes.
2019-12-19 15:09:54 +01:00
Eelco Dolstra
2550c11373
tarfile.cc: Don't change the cwd
...
Nix is multithreaded so it's not safe to change the cwd.
2019-12-19 15:08:16 +01:00
Eelco Dolstra
be32da0ed0
tarfile.cc: Style fixes
2019-12-19 15:01:58 +01:00
Eelco Dolstra
ee235e764c
Merge branch 'libarchive' of https://github.com/yorickvP/nix
2019-12-19 14:47:18 +01:00
Eelco Dolstra
f8abbdd456
Add priority setting to stores
...
This allows overriding the priority of substituters, e.g.
$ nix-store --store ~/my-nix/ -r /nix/store/df3m4da96d84ljzxx4mygfshm1p0r2n3-geeqie-1.4 \
--substituters 'http://cache.nixos.org?priority=100 daemon?priority=10'
Fixes #3264 .
2019-12-17 17:17:53 +01:00
Eelco Dolstra
54bf5ba422
nix-store -r: Handle symlinks to store paths
...
Fixes #3270 .
2019-12-16 19:11:47 +01:00
Eelco Dolstra
ac9cc2ec08
Move some code
2019-12-13 19:10:39 +01:00
Eelco Dolstra
b4edc3ca61
Don't leak exceptions
2019-12-13 19:05:26 +01:00
Eelco Dolstra
e6bd88878e
Improve gzip error message
2019-12-13 19:05:26 +01:00
Eelco Dolstra
ca87707c90
Get rid of CBox
2019-12-13 19:05:26 +01:00
Eelco Dolstra
3e787423c2
Remove FIXME
2019-12-13 12:55:52 +01:00
Tom Bereknyei
c6295a3afd
Initial gzip support
...
Closes #3256
2019-12-13 03:34:15 -05:00
Eelco Dolstra
bbe97dff8b
Make the Store API more type-safe
...
Most functions now take a StorePath argument rather than a Path (which
is just an alias for std::string). The StorePath constructor ensures
that the path is syntactically correct (i.e. it looks like
<store-dir>/<base32-hash>-<name>). Similarly, functions like
buildPaths() now take a StorePathWithOutputs, rather than abusing Path
by adding a '!<outputs>' suffix.
Note that the StorePath type is implemented in Rust. This involves
some hackery to allow Rust values to be used directly in C++, via a
helper type whose destructor calls the Rust type's drop()
function. The main issue is the dynamic nature of C++ move semantics:
after we have moved a Rust value, we should not call the drop function
on the original value. So when we move a value, we set the original
value to bitwise zero, and the destructor only calls drop() if the
value is not bitwise zero. This should be sufficient for most types.
Also lots of minor cleanups to the C++ API to make it more modern
(e.g. using std::optional and std::string_view in some places).
2019-12-10 22:06:05 +01:00
Yorick
eba82b7c88
further clean up libarchive code
2019-12-09 17:21:46 +07:00
puck
28ee687adf
Clean up libarchive support
2019-12-07 18:12:21 +00:00
Yorick
fe7ec70e6b
remove rust unpack_tarfile ffi
2019-12-07 23:28:31 +07:00
Yorick
1355554d12
code 'cleanup'
2019-12-07 23:23:11 +07:00