Commit Graph
24 Commits
Author SHA1 Message Date
zimbatmandregnat 2c4de6af10 add documentation 2020-06-08 09:31:15 +02:00
zimbatm 6ee03b8444 libutils/hash: remove default encoding
This will make it easier to reason about the hash encoding and switch to
SRI everywhere where possible.
2020-06-03 13:49:51 +02:00
zimbatm 895516cadf add NIX_USER_CONF_FILES
Motivation: maintain project-level configuration files.

Document the whole situation a bit better so that it corresponds to the
implementation, and add NIX_USER_CONF_FILES that allows overriding
which user files Nix will load during startup.
2020-04-14 18:45:06 +02:00
zimbatm a08f353922 gitignore /precompiled-headers.h.?ch 2019-11-08 14:48:52 +00:00
zimbatm 9a25059656 findDerivationFilename: add FIXME 2019-10-28 21:40:02 +01:00
zimbatm d407f4d15f nix repl: also handle lambda edit 2019-10-28 21:37:22 +01:00
zimbatm 3774fe55fd editorFor: take a pos object instead 2019-10-28 21:36:34 +01:00
zimbatm ec448f8bb6 libexpr: findDerivationFilename return Pos instead of tuple 2019-10-28 21:29:54 +01:00
zimbatm 59c7249769 libexpr: add findDerivationFilename
extract the derivation to filename:lineno heuristic
2019-10-23 17:21:16 +02:00
zimbatm 207a537343 libutil: add editorFor heuristic 2019-10-23 16:48:28 +02:00
zimbatm 73ff84f6a8 nix repl: add :edit command
This allows to have a repl-centric workflow to working on nixpkgs.

Usage:

    :edit <package> - heuristic that find the package file path

    :edit <path> - just open the editor on the file path

Once invoked, `nix repl` will open $EDITOR on that file path. Once the
editor exits, `nix repl` will automatically reload itself.
2019-10-23 16:09:42 +02:00
zimbatm e63c9e73e3 libstore: don't forward --show-trace 2019-09-22 10:57:20 +00:00
zimbatm 619cc4af85 function-trace: always show the trace
If the user invokes nix with --trace-function-calls it means that they
want to see the trace.
2019-09-18 23:23:21 +02:00
zimbatm b226b5cd97 nix-store: fix out of sync protocol
If a NAR is already in the store, addToStore doesn't read the source
which makes the protocol go out of sync. This happens for example when
two client try to nix-copy-closure the same derivation at the same time.
2019-08-16 15:05:45 +02:00
zimbatm 91b00b145f libutil: add SizedSource
Introduce the SizeSource which allows to bound how much data is being
read from a source. It also contains a drainAll() function to discard
the rest of the source, useful to keep the nix protocol in sync.
2019-08-16 15:05:40 +02:00
zimbatm 9031a6838c Remove .github/FUNDING.yml
The configuration is now done through the shared configuration repo:

https://github.com/nixos/.github
2019-07-23 15:21:23 +02:00
zimbatm 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
zimbatm b402148d8f remove noop uses of nix-store --init
the nix-store --init command is a noop apparently
2019-02-22 21:07:53 +01:00
zimbatm 5e6fa9092f libstore: improve hash mismatch error messages
Use the same output ordering and format everywhere.

This is such a common issue that we trade the single-line error message for
more readability.

Old message:
```
fixed-output derivation produced path '/nix/store/d4nw9x2sy9q3r32f3g5l5h1k833c01vq-example.com' with sha256 hash '08y4734bm2zahw75b16bcmcg587vvyvh0n11gwiyir70divwp1rm' instead of the expected hash '1xzwnipjd54wl8g93vpw6hxnpmdabq0wqywriiwmh7x8k0lvpq5m'
```

New message:
```
hash mismatch in fixed-output derivation '/nix/store/d4nw9x2sy9q3r32f3g5l5h1k833c01vq-example.com':
  wanted: sha256:1xzwnipjd54wl8g93vpw6hxnpmdabq0wqywriiwmh7x8k0lvpq5m
  got:    sha256:08y4734bm2zahw75b16bcmcg587vvyvh0n11gwiyir70divwp1rm

```
2018-12-12 17:42:00 +01:00
zimbatm 865ca2402f nix copy: add an example with S3
I couldn't find a good example how to use it with non-us-east-1 buckets.
2018-03-30 02:31:14 +01:00
zimbatm 43bef1b82c doc: document the min-free and max-free options 2018-03-17 21:29:03 +00:00
zimbatm fef8ebf51d doc: add xml:id to all the config options 2018-03-17 21:17:28 +00:00
zimbatm 45ed6e7ef2 Document the common --no-build-hook option 2016-12-28 14:19:59 +00:00
zimbatm 7d7ec2b3a8 Document the { __toString } interface 2016-09-21 14:52:26 +01:00