1
1
Fork 0
mirror of https://github.com/NixOS/nix.git synced 2025-11-15 06:52:43 +01:00
Commit graph

6053 commits

Author SHA1 Message Date
Eelco Dolstra
444b921fcb
Fix #1921
(cherry picked from commit d34fa2bcc3)
Signed-off-by: Domen Kožar <domen@dev.si>
2018-04-20 12:47:14 +01:00
Shea Levy
dab3a9d37b Export required C++ version in pkgconfig.
(cherry picked from commit a38fe5c1a8)
2018-04-20 11:13:56 +02:00
Shea Levy
51415f1004 Make prim_exec and prim_importNative available to plugins
(cherry picked from commit fd98fca7bb)
2018-04-20 11:13:56 +02:00
Eelco Dolstra
338a3cc0cb
Merge pull request #2093 from grahamc/re-backport-multi-user-linux
Re backport multi user linux, but default to no daemon on Linux
2018-04-20 00:37:22 +02:00
Graham Christensen
572192ec52
installer: allow opting in / out to the daemon installer
By passing --daemon or --no-daemon, the installer can be forced to
select one or the other installation options, despite what the
automatic detection can provide.

This commit can be backported to 2.0-maintenance because it explicitly
turns off the daemon installation for Linux under systemd.

(cherry picked from commit 17b158af85)
2018-04-19 13:56:00 -04:00
Graham Christensen
fa44fa36d1
Revert "Revert "Merge pull request #2027 from grahamc/backport-linux-multi-user""
This reverts commit 4a7b3d1f4c.
2018-04-19 13:55:37 -04:00
Shea Levy
0ccf36be35
ssh-ng: Don't forward options to the daemon.
This can be iterated on and currently leaves out settings we know we
want to forward, but it fixes #1713 and fixes #1935 and isn't
fundamentally broken like the status quo. Future changes are suggested
in a comment.

(cherry picked from commit 088ef81759)
2018-04-19 11:46:25 -04:00
Eelco Dolstra
c67476fb7a
Bump version to 2.0.1 2018-04-19 16:28:28 +02:00
Asad Saeeduddin
e30bd3502e
Wrap thread local in function for Cygwin
Fixes #1826. See #1352 for a previous instance of a similar change.

(cherry picked from commit be54f4a0b6)
2018-04-19 16:28:07 +02:00
Eelco Dolstra
5a01ff6b47
Fix tests.evalNixOS
This failed because NixOS' release.nix calls builtins.fetchGit.

(cherry picked from commit a99027d587)
2018-04-19 16:18:59 +02:00
Eelco Dolstra
f7454db452
Remove Fedora / Ubuntu releases that are no longer in Nixpkgs
(cherry picked from commit ed87fd17dd)
2018-04-19 14:49:58 +02:00
Eelco Dolstra
497325a75d
Remove some release-critical jobs
The release does not in fact depend on Ubuntu/Fedora builds (we don't
publish the build results).

(cherry picked from commit 92aee1b7d6)
2018-04-19 14:49:49 +02:00
Shea Levy
b61ea7b24e
initPlugins: Fix dlopen error message.
(cherry picked from commit dc0a542c9f)
2018-04-18 17:47:59 +02:00
Eelco Dolstra
b1ade66815
Handle arguments in $EDITOR
Fixes #2079.

(cherry picked from commit a4aac7f88c)
2018-04-18 17:47:33 +02:00
Félix Baylac-Jacqué
5be4f48c2d
nix repl: Fix multiline SIGINT handling.
Fixes #2076

(cherry picked from commit a91fb422fe)
2018-04-18 17:47:21 +02:00
Eelco Dolstra
effbbca812
Fix #2057
(cherry picked from commit 1839a5542a)
2018-04-11 11:47:43 +02:00
Shea Levy
f226d56d25
nix-daemon: Exit successfully when interrupted.
Fixes #2058.

(cherry picked from commit 346c0ac361)
2018-04-11 11:47:43 +02:00
Andrew Dunham
2463b4eb07
Fix missing $DESTDIR when installing programs
(cherry picked from commit f8ab9cef6c)
2018-04-11 11:47:43 +02:00
Samuel Dionne-Riel
b8a5acc203
nix-shell: Fixes use with ruby shebangs.
The ported code in 80ebc553ec was incorrectly ported.

```
-            $envCommand = "exec $execArgs $interpreter -e 'load(\"$script\")' -- ${\(join ' ', (map shellEscape, @savedArgs))}";
...
+                    envCommand = (format("exec %1% %2% -e 'load(\"%3%\") -- %4%") % execArgs % interpreter % script % joined.str()).str();
```

The single-quote finishing the small ruby snippet was lost in
translation.

(cherry picked from commit 399f43c3d5)
2018-04-11 11:47:43 +02:00
zimbatm
1e17079915
nix copy: add an example with S3
I couldn't find a good example how to use it with non-us-east-1 buckets.

(cherry picked from commit 865ca2402f)
2018-04-11 11:47:43 +02:00
Eelco Dolstra
3556a7c254
Remove reference to non-existent manpages
(cherry picked from commit 446bb88f13)
2018-04-11 11:47:43 +02:00
Eelco Dolstra
d0699defd6
Process --option use-case-hack properly
Fixes https://github.com/NixOS/nix/issues/2009.

(cherry picked from commit 2b61c74922)
2018-04-11 11:47:43 +02:00
Eelco Dolstra
247630287b
ValidPathInfo::isContentAddressed(): Ensure there are no references
(cherry picked from commit 9d1220a01d)
2018-04-11 11:47:43 +02:00
Tuomas Tynkkynen
59c54f877c
release.nix: Use pkgs.closureInfo for binaryTarball
pathsFromGraph is legacy since Nix 2.0.

(cherry picked from commit cc6712ae90)
2018-04-11 11:47:43 +02:00
Eelco Dolstra
4a7b3d1f4c
Revert "Merge pull request #2027 from grahamc/backport-linux-multi-user"
This reverts commit a198670ab2,
reversing changes made to
a1cc741d9c. For the stable release
branch, we can't really change the fundamental behaviour of the
installer (i.e. by doing a multi-user install on Linux).
2018-04-11 11:47:43 +02:00
Shea Levy
33dc83821d
Document fetchGit.
Fixes #1981.

(cherry picked from commit 6856fe62b0)
2018-04-11 11:47:43 +02:00
Dmitry Kalinkin
26bc4b9557
doc: don't mention obsolete ssh-substituter-hosts
#1840

(cherry picked from commit e2f56c1333)
2018-04-11 11:47:42 +02:00
Corey O'Connor
7a35b10ade
manual: correct repeated "--deriver". Add missing single char option aliases.
(cherry picked from commit 22b144fea6)
2018-04-11 11:47:42 +02:00
Eelco Dolstra
ccb81b2622
Remove unused channel-cache directory
(cherry picked from commit 03d8136b02)
2018-04-11 11:47:42 +02:00
Eelco Dolstra
073dac149b
Don't retry on CURLE_SSL_CACERT_BADFILE
The certificates won't get any better if we retry.

(cherry picked from commit eb75bc5afb)
2018-04-11 11:47:42 +02:00
Eelco Dolstra
225ae5b62a
Filter ANSI colors when not writing to a terminal
Fixes https://github.com/NixOS/nixpkgs/issues/37114.

(cherry picked from commit 4868721506)
2018-04-11 11:47:42 +02:00
Will Dietz
434cdab511
nix-daemon: preserve errno in signal handler (thanks tsan)
(cherry picked from commit d98755b0c2)
2018-04-11 11:47:42 +02:00
Eelco Dolstra
ac5a36c2f3
build-remote: Don't substitute the build result
(cherry picked from commit 7afdc8d4a1)
2018-04-11 11:47:42 +02:00
Eelco Dolstra
25b24a5542
Typo
(cherry picked from commit 6e60141a80)
2018-04-11 11:47:42 +02:00
Guillaume Maudoux
4c737abe3e
fetchGit: Fix debug message
(cherry picked from commit 80735c4cc9)
2018-04-11 11:47:42 +02:00
Eelco Dolstra
dd214bb087
Fix double free in Store::queryPathInfo()
It was holding on to a Value* (i.e. a std::shared_ptr<ValidPathInfo>*)
outside of the pathInfoCache lock, so the std::shared_ptr could be
destroyed between the release of the lock and the decrement of the
std::shared_ptr refcount. This can happen if more than
'path-info-cache-size' paths are added in the meantime, *or* if
clearPathInfoCache() is called. The hydra-queue-runner queue monitor
thread periodically calls the later, so is likely to trigger a crash.

Fixes https://github.com/NixOS/hydra/issues/542.

(cherry picked from commit 24b739817f)
2018-04-11 11:47:42 +02:00
Eelco Dolstra
d306287abd
Fix #1957
(cherry picked from commit 16551f54c9)
2018-04-11 11:47:41 +02:00
Will Dietz
33bfcbdbdd
release.nix: don't try to use nix-2.0 branch, no longer exists
Probably should point at the 18.03 release branch once that's made.

(cherry picked from commit e9a5ce9b07)
2018-04-11 11:47:41 +02:00
Eelco Dolstra
2bbea0d96f
Fix error message
(cherry picked from commit 939cf4cceb)
2018-04-11 11:47:41 +02:00
Michael Fiano
d64618de01
nix-channel grammar and punctuation
Minor changes to the nix-channel manpage for my first contribution

(cherry picked from commit ad97d1a786)
2018-04-11 11:47:41 +02:00
Will Dietz
5df25a35b7
fetchGit: use "HEAD" as default ref
(cherry picked from commit e89d02bf03)
2018-04-11 11:47:41 +02:00
Shea Levy
7e989da790
Actually fix nixDataDir in non-canonical path
(cherry picked from commit 14ca85688c)
2018-04-11 11:47:41 +02:00
Tuomas Tynkkynen
77a2cd2f5e
libexpr: Fix prim_replaceStrings() to work on an empty source string
Otherwise, running e.g.

nix-instantiate --eval -E --strict 'builtins.replaceStrings [""] ["X"] "abc"'

would just hang in an infinite loop.

Found by afl-fuzz.

First attempt of this was reverted in e2d71bd186 because it caused
another infinite loop, which is fixed now and a test added.

(cherry picked from commit 77e9e1ed91)
2018-04-11 11:47:41 +02:00
Eelco Dolstra
d0665a22cc
nix run: Fix segfault on macOS
Note that clearenv() is not available on macOS.

Fixes #1907.

(cherry picked from commit 24ec750003)
2018-04-11 11:47:41 +02:00
Will Dietz
bdd88cabd3
nix search: explicitly handle empty search string, fixes #1893
This is important since this is given as an example.
Other patterns containing "empty search string" will still
be handled differently on different platforms ("asdf|")
but that's less of an issue.

(cherry picked from commit 009cf9cd23)
2018-04-11 11:47:41 +02:00
Will Dietz
e9c5be6fe7
nix search: fix bug where we wrote to cache when shouldn't, breaking
This is exposed by the tests added previously,
and resolves the error reported in #1892:
"expected JSON value".

(cherry picked from commit 3cac8734ac)
2018-04-11 11:47:41 +02:00
Eelco Dolstra
0995763eb1
Fix downloadCached() with a chroot store
E.g.

  nix run --store ~/my-nix -f channel:nixos-17.03 hello -c hello

This problem was mentioned in #1897.

(cherry picked from commit 64e486ab63)
2018-04-11 11:47:41 +02:00
Eelco Dolstra
741a9e9ec3
Fix example in release notes
(cherry picked from commit 39b4177500)
2018-04-11 11:47:40 +02:00
Eelco Dolstra
af81bb7845
Doh
(cherry picked from commit 2691d51a33)
2018-04-11 11:47:40 +02:00
Linus Heckemann
3b9eb5385f
Fix #1762
nix-store --export, nix-store --dump, and nix dump-path would previously
fail silently if writing the data out failed, because
 a) FdSink::write ignored exceptions, and
 b) the commands relied on FdSink's destructor, which ignores
    exceptions, to flush the data out.

This could cause rather opaque issues with installing nixos, because
nix-store --export would happily proceed even if it couldn't write its
data out (e.g. if nix-store --import on the other side of the pipe
failed).

This commit adds tests that expose these issues in the nix-store
commands, and fixes them for all three.

(cherry picked from commit 78ac3eb4eb)
2018-04-11 11:47:40 +02:00