Commit graph

15154 commits

Author SHA1 Message Date
Arthur Gautier
85e5ac403f
docker: publish images to ghcr.io (#8066)
* docker: publish images to ghcr.io

docker.com announced their intention to remove the free plan used by
OSS. The nixos/nix image is essential to various CI runs to build with
nix. To provide a continuity plan, this commit pushes the image to
ghcr.io as well.

Co-authored-by: Sandro <sandro.jaeckel@gmail.com>
2023-10-20 19:28:26 +02:00
Eelco Dolstra
e824ab30cf
Merge pull request #9195 from edolstra/remove-hasAllInfo
Input::hasAllInfo(): Remove
2023-10-20 18:57:56 +02:00
Eelco Dolstra
af302267e5 Input::hasAllInfo(): Remove 2023-10-20 17:19:36 +02:00
Robert Hensing
4d17c59d8d
Merge pull request #9157 from obsidiansystems/protocol-versions
Add protocol versions to `{Worker,Serve}Proto::*Conn`
2023-10-20 15:34:26 +02:00
John Ericson
8a28ed2e8b
Merge pull request #9187 from hercules-ci/issue-7619-apple-virt-system-feature
libstore: Add `apple-virt` to system features when available
2023-10-20 09:09:20 -04:00
Robert Hensing
bb645c5d02 system-features doc: kvm is Linux-only 2023-10-20 10:21:39 +02:00
Robert Hensing
9277eb276b libstore: Add apple-virt to system features when available
I'm sure that we'll adjust the implementation over time, but this
at least discerns between an apple silicon bare metal machine and
a tart VM.
2023-10-20 10:21:39 +02:00
Johannes Kirschbauer
e58566a057
doc: add reference to hasAttr in ? operator (#9185)
Co-authored-by: Valentin Gagarin <valentin.gagarin@tweag.io>
2023-10-20 03:11:03 +00:00
Johannes Kirschbauer
42f26eb42e
doc: complexity for '?' operator (#9184)
Co-authored-by: Valentin Gagarin <valentin.gagarin@tweag.io>
Co-authored-by: Robert Hensing <roberth@users.noreply.github.com>
2023-10-20 02:45:47 +02:00
John Ericson
7ed294f07d
Merge pull request #9182 from fricklerhandwerk/popular-issues
link to popular issues from the contributing guide
2023-10-19 16:25:36 -04:00
John Ericson
6016a0ed09
Merge pull request #9181 from fricklerhandwerk/good-first-issue-label
update link to label
2023-10-19 16:24:57 -04:00
John Ericson
ce42655ef6
Merge pull request #9180 from fricklerhandwerk/meeting-notes-link
add a link to all maintainer meeting notes
2023-10-19 16:24:37 -04:00
Johannes Kirschbauer
9bc7b4f463
doc: generic closure supported key types (#9183)
* doc: generic closure supported key types

Co-authored-by: Valentin Gagarin <valentin.gagarin@tweag.io>
2023-10-19 12:39:41 +00:00
Valentin Gagarin
36b15d905e link to popular issues from the contributing guide
this also adds a hint to contributors about making far-reaching changes,
complementing the recent update to the maintainers' handbook on how to
deal with those.
2023-10-19 11:47:10 +02:00
Valentin Gagarin
9adac237e7 update link to label
GitHub now displays a banner and has a dedicated page[1] for good first
issues, but that uses a different label name as we had in place.
I renamed the label on GitHub, this is updating the link.

[1]: https://github.com/NixOS/nix/contribute
2023-10-19 11:40:30 +02:00
Valentin Gagarin
8b48fb146b
Merge pull request #7708 from ShamrockLee/primop-rebasehash
primops: add builtins.convertHash
2023-10-19 11:38:47 +02:00
Valentin Gagarin
34c5593525 add a link to all maintainer meeting notes
linking to the discourse category will by default show a view sorted by
most recent post, which makes it hard to find particular meeting notes.

this also adds a procedural detail about the notes, to make that more
explicit and less dependent on being present in the meetings.
2023-10-19 10:57:45 +02:00
Yueh-Shun Li
5088e6563a primops: add builtins.convertHash
Co-authored-by: Valentin Gagarin <valentin.gagarin@tweag.io>
2023-10-19 00:58:56 +08:00
Yueh-Shun Li
6b47635180 Add helper function parseHashFormat[Opt] printHashFormat
Add hash format analogy of
parseHashTypeOpt, parseHashType, and printHashType.

Co-authored-by: Valentin Gagarin <valentin.gagarin@tweag.io>
2023-10-19 00:56:44 +08:00
Yueh-Shun Li
231b0fca6d Migrate HashFormat to scoped enumeration (enum struct) 2023-10-19 00:56:44 +08:00
Yueh-Shun Li
e026f3e1ae treewide: Reference HashFormat members with scope
Base* -> HashFormat::Base*
2023-10-19 00:56:41 +08:00
Yueh-Shun Li
5043e6cf4e Document HashFormat 2023-10-19 00:38:32 +08:00
Yueh-Shun Li
838c70f621 treewide: Rename hashBase to hashFormat
hashBase is ambiguous, since it's not about the digital bases, but about
the format of hashes. Base16, Base32 and Base64 are all character maps
for binary encoding.

Rename the enum Base to HashFormat.

Rename variables of type HashFormat from [hash]Base to hashFormat,
including CmdHashBase::hashFormat and CmdToBase::hashFormat.
2023-10-19 00:38:32 +08:00
Yueh-Shun Li
aff177d860 Elaborate the "unknown hash algorithm" error
List the allowed hash formats
2023-10-19 00:38:32 +08:00
Yueh-Shun Li
e9ddf0b400 Simplify parseHashTypeOpt
Remove redundant "else" after "return".

Use std::nullopt to increase readability.
2023-10-19 00:38:32 +08:00
Eelco Dolstra
201c115c3e
Merge pull request #9151 from edolstra/stabilize-fetchTree
Stabilize fetchTree
2023-10-18 10:54:08 +02:00
Théophane Hufschmitt
c1a1766c46
Merge pull request #9169 from vkryachko/follow_cycle
Detect cycles in flake follows.
2023-10-18 07:34:03 +02:00
John Ericson
9d1f42db52
Merge pull request #9150 from vicky1999/fix/8914
`nix store ping` -> `nix store info`
2023-10-17 22:52:28 -04:00
vicky1999
891dfb4359 updated store ping to store info in files 2023-10-18 00:14:11 +05:30
vicky1999
a0f071f1d3 store info sh renamed 2023-10-18 00:12:10 +05:30
John Ericson
e36c9175f4 Add protocol versions to {Worker,Serve}Proto::*Conn
This will allow us to factor out logic, which is currently scattered
inline, into several reusable instances

The tests are also updated to support versioning. Currently all Worker
and Serve protocol tests are using the minimum version, since no
version-specific serialisers have been created yet. But in subsequent
commits when that changes, we will test individual versions to ensure
complete coverage.
2023-10-17 11:21:10 -04:00
John Ericson
ff68426095 Name the protocol version types
This makes the code clearer, and will help us replace them with proper
structs and get rid of the macros later.
2023-10-17 11:20:39 -04:00
Eelco Dolstra
3470cd68c4 Mark some fetchers as experimental 2023-10-17 14:57:29 +02:00
Eelco Dolstra
f62b5500ff fetchTree: Require the flakes experimental feature for the URL syntax 2023-10-17 14:52:34 +02:00
Eelco Dolstra
e92cac789f
Merge pull request #9168 from obsidiansystems/fix-lang-tests-read-only
Fix language tests a bit
2023-10-17 14:45:38 +02:00
Eelco Dolstra
a9b8595fd9
Merge pull request #9162 from eclairevoyant/add-mainprogram
explicitly set meta.mainProgram
2023-10-17 14:44:29 +02:00
vicky1999
dcc5f801f4 Store info command help updates 2023-10-17 09:39:59 +05:30
John Ericson
8c049a9f04
Merge pull request #9172 from tfc/bad-moves
Fix/remove some bad std::moves
2023-10-16 17:46:41 -04:00
Jacek Galowicz
54b350d517 Drop some moves that would happen anyway but forbid NRVO where appicable 2023-10-16 21:48:35 +01:00
Jacek Galowicz
abf7df2b37 Fix moves that accidentally copy anyway 2023-10-16 21:48:35 +01:00
Vladimir Kryachko
d6066c90f8 Don't convert InputPaths to strings prematurely. 2023-10-16 15:47:28 -04:00
John Ericson
aa4f41d796
Merge pull request #9170 from tfc/fix-broken-move
Fix broken move
2023-10-16 15:13:03 -04:00
Jacek Galowicz
add066cc7b Fix broken move 2023-10-16 19:32:47 +01:00
Vladimir Kryachko
b3fd7db63f Detect cycles in flake follows.
This change results in an error thrown as opposed to segfaulting due to
stack overflow.

Fixes #9144
2023-10-16 13:00:49 -04:00
John Ericson
f7a36f9812 Fix language tests a bit
- Remove some stray saved error messages that didn't correspond to any
  test, because they were renamed in
  d11faa01b5.

- Need `--eval` in test failure test in order to get in "read-only" mode
  where we don't try to write to the store. (The other tests already do
  this.)

- Need `--strict` so top-level attribute sets are still forced, like
  they are without `--eval`.
2023-10-16 12:52:59 -04:00
John Ericson
5442d9b472
Merge pull request #9167 from obsidiansystems/pre-overhaul-completions
Improve tests and docs prior to refactoring completions
2023-10-16 12:12:28 -04:00
John Ericson
483d99c622 Add API docs to some args-related functionality 2023-10-16 11:25:15 -04:00
John Ericson
c27d2f8da9 Add two more completions tests
Thanks @ncfavier for catching these regressions in my PR.

Co-Authored-By: Naïm Favier <n@monade.li>
2023-10-16 10:09:10 -04:00
John Ericson
d12c614ac7
Merge pull request #9152 from obsidiansystems/split-out-perl-nix
Factor out Perl bindings Nix package
2023-10-16 09:57:37 -04:00
Eelco Dolstra
6bf68c1e64
Merge pull request #8904 from wentasah/metadata-shows-last-modified
nix flakes metadata: Show lastModified timestamp for each input
2023-10-16 13:52:51 +02:00