Eelco Dolstra
218cd6c16c
Merge pull request #11981 from h0nIg/patch-2
...
docker: Fix command "nix profile install", Don't require --impure (fix for 2.25)
2024-11-29 12:53:47 +01:00
h0nIg
61950c3375
docker: Fix command "nix profile install", Don't require --impure
2024-11-27 13:35:18 +01:00
Jörg Thalheim
282bfbdacb
Merge pull request #11973 from NixOS/mergify/bp/2.25-maintenance/pr-11959
...
more readable errors if symlinks cannot be created (backport #11959 )
2024-11-27 08:04:06 +01:00
Jörg Thalheim
14432ea4a2
Merge pull request #11962 from NixOS/mergify/bp/2.25-maintenance/pr-11915
...
Bump fetcher cache version (backport #11915 )
2024-11-27 07:23:52 +01:00
Jörg Thalheim
8d51c90872
more readable errors if symlinks cannot be created
...
Before:
filesystem error: cannot create symlink: Permission denied [/nix/store/1s2p3a4rs172336hj2l8n20nz74hf71j-nix-eval-jobs-2.24.1.drv] [/1s2p3a4rs172336hj2l8n20nz74hf71j-nix-eval-jobs-2.24.1.drv.tmp-2772352-1316231068]
Now:
creating symlink '/wfxz2q489c811n08cdqj7ywxm3n4z6m5-nix-eval-jobs-2.24.1.drv.tmp-2971297-324653080' -> '/nix/store/wfxz2q489c811n08cdqj7ywxm3n4z6m5-nix-eval-jobs-2.24.1.drv': Permission denied
(cherry picked from commit 5b8728d393
)
# Conflicts:
# src/nix/flake.cc
2024-11-27 07:21:10 +01:00
Eelco Dolstra
118d50992c
Merge pull request #11968 from NixOS/mergify/bp/2.25-maintenance/pr-11878
...
Remove warning that interpretation of .drv has changed (backport #11878 )
2024-11-26 14:51:50 +01:00
Eelco Dolstra
9f9b2ed48c
Merge pull request #11966 from NixOS/mergify/bp/2.25-maintenance/pr-11876
...
Filter OSC 8 correctly (backport #11876 )
2024-11-26 14:10:16 +01:00
Eelco Dolstra
eb50683e81
Merge pull request #11965 from NixOS/mergify/bp/2.25-maintenance/pr-11884
...
nix path-info: Don't write to std::cout directly (backport #11884 )
2024-11-26 13:58:42 +01:00
Eelco Dolstra
c381199e97
Merge pull request #11964 from NixOS/mergify/bp/2.25-maintenance/pr-11901
...
tests/functional/flakes/develop.sh: Don't hang (backport #11901 )
2024-11-26 13:35:14 +01:00
Eelco Dolstra
072ebeee79
Merge pull request #11963 from NixOS/mergify/bp/2.25-maintenance/pr-11902
...
Fix issue #11892 (backport #11902 )
2024-11-26 13:16:35 +01:00
Robert Hensing
3501c737d3
Remove warning that interpretation of .drv has changed
...
This was first tagged as 2.15.0, 1½ years ago; plenty of time for
everyone to catch up.
By now, the warning is causing more confusion than that it is helpful,
because passing a `.drv` or `drvPath` has legitimate use cases.
(cherry picked from commit f534a7a524
)
2024-11-26 11:27:41 +00:00
Jack Wilsdon
12eff94815
Filter OSC 8 correctly
...
This allows Nix to use lowdown 1.2.0 which outputs OSC-8 links.
(cherry picked from commit 1301f8434d
)
2024-11-26 11:20:35 +00:00
Eelco Dolstra
89f4ac3d2c
nix path-info: Don't write to std::cout directly
...
This interferes with the progress bar, resulting in output like
evaluating derivation 'git+file:///home/eelco/Dev/nix-master#packages.x86_64-linux.default'/nix/store/zz8v96j5md952x0mxfix12xqnvq5qv5x-nix-2.26.0pre20241114_a95f6ea.drv
(cherry picked from commit 33a0fa882f
)
2024-11-26 11:20:35 +00:00
Eelco Dolstra
1dbe60e073
tests/functional/flakes/develop.sh: Don't hang
...
The bash shell started by `nix develop` waited forever for stdin
input.
Fixes #11827 .
(cherry picked from commit 428af8c66f
)
2024-11-26 11:19:33 +00:00
Robert Hensing
4e2824ce93
Bump fetcher cache version
...
We're getting more reports in https://github.com/NixOS/nix/issues/10985
It appears that something hasn't gone right process-wise.
I find this mistake not to be worth investigating, but rather something
to pay attention to going forward.
Let's nip this in the bud.
Closes https://github.com/NixOS/nix/issues/10985
(cherry picked from commit e948c8e033
)
2024-11-26 11:19:29 +00:00
Robert Hensing
3bc3e55736
Fix issue 11892
...
It seems that I copied the expression for baseDir thoughtlessly and
did not come back to it.
- `baseDir` was only used in the `fromArgs` branch.
- `fromArgs` is true when `packages` is true.
(cherry picked from commit c4b95dbdd1
)
2024-11-26 11:19:29 +00:00
Eelco Dolstra
d97ebe519a
Bump version
2024-11-14 11:37:15 +01:00
Eelco Dolstra
f87f87120a
Bump version
2024-11-13 21:04:28 +01:00
Eelco Dolstra
5ae53d4730
nix-everything: Pass through a version attribute
...
The existence of this attribute is assumed by the Determinate
Installer packaging and maybe others.
(cherry picked from commit 06769eb2bf
)
2024-11-13 14:49:51 +01:00
Eelco Dolstra
7bc52df684
Merge pull request #11861 from DeterminateSystems/nix-2.25-default
...
[2.25] Make the default package point to the old build
2024-11-12 17:12:12 +01:00
Eelco Dolstra
3e883b9eaf
Make the default package point to the old build
...
There are some differences that are causing issues, like the fact that
nix-ng doesn't have a version attribute.
2024-11-12 16:26:40 +01:00
Eelco Dolstra
6b96c66302
Merge pull request #11856 from nix-windows/fix-windows-env-var-arg-order
...
[Backport 2.25] Fix argument order in the Windows implementation of `getEnvOs`
2024-11-12 11:04:59 +01:00
John Ericson
355f08a728
Fix argument order in the Windows implementation of getEnvOs
...
See the build failure in https://github.com/msys2/MINGW-packages/pull/22499
2024-11-12 00:52:17 -05:00
Eelco Dolstra
9213bf55ce
Bump version
2024-11-11 17:08:24 +01:00
Eelco Dolstra
5c5a737885
Mark stable release
2024-11-11 15:14:57 +01:00
Eelco Dolstra
fa4bd39c6a
Merge pull request #11701 from DeterminateSystems/flake-substitution
...
Restore input substitution
2024-11-11 14:40:22 +01:00
Eelco Dolstra
036359ac84
Remove release note about flake substitution
2024-11-11 13:58:12 +01:00
Eelco Dolstra
67a42e6240
Merge remote-tracking branch 'origin/master' into flake-substitution
2024-11-11 13:57:24 +01:00
Valentin Gagarin
17c94b7ff7
Merge pull request #11842 from DeterminateSystems/release-notes
...
Nix 2.25 release notes
2024-11-11 12:24:05 +01:00
Robert Hensing
6f50e6a3fa
maintainers/onboarding: Subscribe to discourse category ( #11848 )
...
Co-authored-by: Valentin Gagarin <valentin@gagarin.work>
2024-11-10 22:20:06 +00:00
Robert Hensing
545956d56a
Merge pull request #11849 from NixOS/autocall-const
...
autoCallFunction: accept const Bindings &
2024-11-10 21:31:11 +01:00
Robert Hensing
a3613f2a3c
autoCallFunction: accept const Bindings &
...
It does not need to mutate the attrs.
`const` is shallow.
Avoids a const_cast in the hercules-ci-cnix-expr bindings.
2024-11-10 20:52:05 +01:00
Jörg Thalheim
aa9c0bc1ee
Merge pull request #11843 from xokdvium/dev/move-fixes
...
fix(treewide): clean up move semantics
2024-11-09 21:57:27 +01:00
Jörg Thalheim
cdcf9bd2fa
Merge pull request #11847 from xokdvium/dev/some-vector-reserves
...
refactor(treewide): reserve vector capacity when final size is known
2024-11-09 21:49:36 +01:00
Jörg Thalheim
6e55f2cf86
Merge pull request #11846 from xokdvium/dev/noexcept-more-ctors-where-possible
...
refactor(treewide): make some move ctors noexcept where appropriate
2024-11-09 21:48:26 +01:00
Sergei Zimmerman
0fe3b54ee1
refactor(treewide): reserve vector capacity when final size is known
...
In these trivial cases the final vector size (or lower bound on the size) is known,
so we can avoid some vector reallocations. This is not very important, but is just
good practice and general hygiene.
2024-11-09 22:40:49 +03:00
Sergei Zimmerman
96eeb6f4ff
refactor(treewide): make some move ctors noexcept where appropriate
...
This is good practice to avoid pessimisations.
Left comments for the reasoning why ctors should be noexcept.
There are some tricky cases where we intentionally want throwing move ctors/assignments.
But those cases should really be reviewed, since some of those can be replaced
with more idiomatic copy/move-and-swap.
2024-11-09 12:09:33 +03:00
Eelco Dolstra
4dceca51de
Don't allow __final in fetchTree
...
It's now only allowed in fetchFinalTree, which is not exposed to users
but only to call-flake.nix.
2024-11-08 19:27:54 +01:00
Sergei Zimmerman
0347bca15b
fix(libstore/path-info): make ValidPathInfo move constructible/assignable
2024-11-08 20:48:00 +03:00
Sergei Zimmerman
149802b9f5
fix(libstore): make BasicDerivation move-constructible/assignable
2024-11-08 20:10:38 +03:00
Sergei Zimmerman
8dd787fbf6
fix(libutil): remove no-op move from const
2024-11-08 20:10:38 +03:00
Sergei Zimmerman
6c3f720e2c
fix(treewide): move arguments where needed
...
Moving from arguments where it should be done.
2024-11-08 20:10:38 +03:00
Sergei Zimmerman
af63d67ba5
fix(libutils): make ref move assignable/constructible
2024-11-08 20:10:38 +03:00
Sergei Zimmerman
17b49134fa
fix(treewide): fix incorrect usage of std::move
...
`auto &&` and `T &&` are forwarding references and can be
either lvalue or rvalue references. Moving from universal references
is incorrect and should not be done.
Moving from integral or floating-point values is pointless and just
worsens debug performance.
2024-11-08 20:10:38 +03:00
Eelco Dolstra
d90b56d527
Remove no longer needed hack
2024-11-08 17:31:35 +01:00
Eelco Dolstra
397f3c544e
Add credits
2024-11-08 17:10:20 +01:00
Eelco Dolstra
d228c00614
Trim release notes
2024-11-08 17:06:49 +01:00
Eelco Dolstra
ecb418e163
Merge remote-tracking branch 'origin/master' into flake-substitution
2024-11-08 16:42:12 +01:00
Jörg Thalheim
492c678162
Merge pull request #11837 from xokdvium/dev/fix-use-after-move-posix-source
...
fix(libutil/posix-source-accessor.cc): get rid of use-after-move bug
2024-11-08 14:56:50 +01:00
Sergei Zimmerman
3e0129ce3b
fix(libutil/posix-source-accessor.cc): get rid of use-after-move bug
...
Naming class member variables the same as constructor arguments is a very
slippery slope because of how member variable names get resolved. Compiler
is not very helpful here and we need static analysis to forbid this kind of
stuff.
The following example illustrates the cause quite well:
```cpp
struct B {
B(int) {}
};
struct A {
A(int b): b([&](){
return b;
static_assert(std::is_same_v<decltype(b), int>);
}()) {
static_assert(std::is_same_v<decltype(b), int>);
}
void member() {
static_assert(std::is_same_v<decltype(b), B>);
}
B b;
};
int main() {
A(1).member();
}
```
From N4861 6.5.1 Unqualified name lookup:
> In all the cases listed in [basic.lookup.unqual], the scopes are searched
> for a declaration in the order listed in each of the respective categories;
> name lookup ends as soon as a declaration is found for the name.
> If no declaration is found, the program is ill-formed.
In the affected code there was a use-after-move for all accesses in the constructor
body, but this UB wasn't triggered.
These types of errors are trivial to catch via clang-tidy's [clang-analyzer-cplusplus.Move].
2024-11-08 16:07:45 +03:00