Nick Van den Broeck
4ad4e48668
FlakeRegistry = FlakeRef -> FlakeRef
2019-04-11 07:08:04 +02:00
Nick Van den Broeck
c64f98b883
FlakeAlias is implemented
2019-04-09 10:16:02 +02:00
Nick Van den Broeck
f39670c631
Took ref and rev out of FlakeRef
2019-04-09 09:51:42 +02:00
Nick Van den Broeck
3ec0c82fab
Fixed dependency resolution
2019-04-09 09:51:42 +02:00
Nick Van den Broeck
641db127be
FlakeIds are now properly looked up in registries
2019-04-09 09:51:36 +02:00
Nick Van den Broeck
18c019b616
Added nonFlakeRequires and the command nix flake deps
2019-04-09 08:38:09 +02:00
Eelco Dolstra
87033f2c4e
Whitespace
2019-04-08 23:58:33 +02:00
Eelco Dolstra
c996e04aca
Allow relative paths in flakerefs
...
Also allow "." as an installable to refer to the flake in the current
directory. E.g.
$ nix build .
will build 'provides.defaultPackage' in the flake in the current
directory.
2019-04-08 23:52:09 +02:00
Eelco Dolstra
507da65900
Move flake template into a separate file
2019-04-08 23:39:38 +02:00
Eelco Dolstra
47727252ff
Add "nix flake init" command for creating a flake
2019-04-08 23:36:12 +02:00
Eelco Dolstra
ee1254d4f5
nix: Add --impure as a shorter alias of --no-pure-eval
2019-04-08 23:19:19 +02:00
Eelco Dolstra
6a4c7fb975
Add path flakeref variant
...
Unlike file://<path>, this allows the path to be a dirty Git tree, so
nix build /path/to/flake:attr
is a convenient way to test building a local flake.
2019-04-08 23:09:18 +02:00
Eelco Dolstra
4023ae4cdf
nix: Support nixpkgs.<attrpath> for compatibility
2019-04-08 16:22:04 +02:00
Eelco Dolstra
101d964a59
nix: Make -f work for compatibility
2019-04-08 16:11:17 +02:00
Eelco Dolstra
9b7eac332b
Merge remote-tracking branch 'origin/master' into flakes
2019-04-08 14:23:48 +02:00
Eelco Dolstra
154244adc6
nix: New installables syntax
...
The general syntax for an installable is now
<flakeref>:<attrpath>. The attrpath is relative to the flake's
'provides.packages' or 'provides' if the former doesn't yield a
result. E.g.
$ nix build nixpkgs:hello
is equivalent to
$ nix build nixpkgs:packages.hello
Also, '<flakeref>:' can be omitted, in which case it defaults to
'nixpkgs', e.g.
$ nix build hello
2019-04-08 14:21:13 +02:00
Eelco Dolstra
6b0ca8e803
findAlongAttrPath(): Throw AttrPathNotFound
2019-04-08 14:20:58 +02:00
Eelco Dolstra
41ba5135e0
primeCache(): Barf if builds are needed but not allowed
...
Fixes #2753 .
2019-04-01 21:09:49 +02:00
Eelco Dolstra
2bc6304793
getMachines(): Cache result
2019-04-01 21:09:35 +02:00
Eelco Dolstra
f32fbf952d
Fix Bison 3.3 warning
2019-03-27 21:09:31 +01:00
Eelco Dolstra
c101b29133
Merge remote-tracking branch 'tweag/flake-registries' into flakes
2019-03-27 14:40:36 +01:00
Eelco Dolstra
be7fd63595
Remove debug line
2019-03-26 14:25:43 +01:00
Eelco Dolstra
f9c7176a87
nix flake add: Handle ~/.config/nix not existing
...
Fixes
$ nix flake add fnord github:edolstra/fnord
error: opening file '/home/eelco/.config/nix/registry.json': No such file or directory
2019-03-26 12:48:57 +01:00
Eelco Dolstra
42be60c6af
Merge remote-tracking branch 'tweag/flake-add' into flakes
2019-03-26 12:35:27 +01:00
Eelco Dolstra
edb3836696
Merge remote-tracking branch 'tweag/auto-update-flake' into flakes
2019-03-26 11:50:22 +01:00
Eelco Dolstra
b5565a7081
Merge remote-tracking branch 'origin/master' into flakes
2019-03-26 11:44:14 +01:00
Eelco Dolstra
5c05c238e6
Merge pull request #1828 from zimbatm/isPath
...
Add isPath primop
2019-03-25 19:58:11 +01:00
Will Dietz
42e2d5e7b7
store-api.hh: add missing include for unordered_map
2019-03-25 09:18:30 +01:00
Jonas Chevalier
514b3c7f83
Add isPath primop
...
this is added for completeness' sake since all the other possible
`builtins.typeOf` results have a corresponding `builtins.is<Type>`
2019-03-24 11:36:49 +01:00
Nick Van den Broeck
a554f523db
Combining registries properly
2019-03-23 13:42:48 +01:00
Nick Van den Broeck
5e4d92d267
Issue #15 is finished
2019-03-22 15:22:18 +01:00
Nick Van den Broeck
e007f367bd
Fixed minor things
2019-03-22 11:21:49 +01:00
Nick Van den Broeck
d4ee8afd59
Implemented --flake flag for nix build
...
Also fixed Eelco's PR comments
2019-03-22 11:16:20 +01:00
Linus Heckemann
2aa89daab3
eval: improve type description for primops and applied primops
...
This can make type errors a little easier to understand.
2019-03-21 15:31:46 +01:00
Chaker Benhamed
81a23fa7e2
Add a 5 seconds of timeouts to connect to S3.
...
The default is 1000ms, but we can hit it a lot of we don't have direct
link to AWS (e.g. using VPN).
2019-03-15 13:23:58 +01:00
Eelco Dolstra
1f64f4c7c8
pkg-config files: Use c++17
2019-03-14 14:11:12 +01:00
Eelco Dolstra
ef52ccf035
experimental/optional -> optional
2019-03-14 14:10:52 +01:00
Eelco Dolstra
86f3b94c8c
nix-store --gc --print-roots: Sort output
2019-03-14 13:59:10 +01:00
Eelco Dolstra
578ed7a259
findRoots(): Don't censor for trusted users
...
They're pretty much root anyway.
2019-03-14 13:53:34 +01:00
Eelco Dolstra
53522cb6ac
findRoots(): Add 'censor' parameter
...
This is less brittle than filtering paths after the fact in
nix-daemon.
2019-03-14 13:53:34 +01:00
Eelco Dolstra
a3f37d87ea
findRuntimeRoots: Simplify/fix handling of /proc files
...
Scanning of /proc/<pid>/{exe,cwd} was broken because '{memory:' was
prepended twice. Also, get rid of the whole '{memory:...}' thing
because it's unnecessary, we can just list the file in /proc directly.
2019-03-14 13:30:25 +01:00
Guillaume Maudoux
4f4391193c
Fix warning about unused variable
2019-03-10 00:56:09 +01:00
Guillaume Maudoux
38ee16ae9c
Unify internal findRootsXxx() api
2019-03-10 00:56:09 +01:00
Guillaume Maudoux
9d7221183a
unify naming of roots as links & targets
2019-03-10 00:56:09 +01:00
Guillaume Maudoux
5c56570726
Also obfuscate the number of memory roots
2019-03-10 00:56:09 +01:00
Guillaume Maudoux
fc02b1b3ee
Also print rooted path in nix-store -q --roots
2019-03-10 00:56:09 +01:00
Guillaume Maudoux
8574b70342
fixup! Make roots a map of store paths to pinning links
2019-03-10 00:56:09 +01:00
Guillaume Maudoux
ebc86550f9
Make roots a map of store paths to pinning links
...
This new structure makes more sense as there may be many sources rooting
the same store path. Many profiles can reference the same path but this
is even more true with /proc/<pid>/maps where distinct pids can and
often do map the same store path.
This implementation is also more efficient as the `Roots` map contains
only one entry per rooted store path.
2019-03-10 00:56:09 +01:00
Guillaume Maudoux
a17f86ce3a
Obfuscate memory roots for non-root users
2019-03-10 00:56:09 +01:00
Guillaume Maudoux
43331d6344
detail memory roots
2019-03-10 00:56:09 +01:00