mirror of
https://github.com/NixOS/nix
synced 2025-07-07 01:51:47 +02:00
Add docs/rl-notes for nix hash convert
/ builtins.convertHash
https://github.com/NixOS/nix/issues/8876
This commit is contained in:
parent
7ff876b92b
commit
8afeaf05c4
4 changed files with 74 additions and 5 deletions
22
doc/manual/rl-next/hash-format-nix32.md
Normal file
22
doc/manual/rl-next/hash-format-nix32.md
Normal file
|
@ -0,0 +1,22 @@
|
|||
synopsis: Rename hash format `base32` to `nix32`
|
||||
prs: #9452
|
||||
description: {
|
||||
|
||||
Hash format `base32` was renamed to `nix32` since it used a special nix-specific character set for
|
||||
[Base32](https://en.wikipedia.org/wiki/Base32).
|
||||
|
||||
## Deprecation: Use `nix32` instead of `base32` as `toHashFormat`
|
||||
|
||||
For the builtin `convertHash`, the `toHashFormat` parameter now accepts the same hash formats as the `--to`/`--from`
|
||||
parameters of the `nix hash conert` command: `"base16"`, `"nix32"`, `"base64"`, and `"sri"`. The former `"base32"` value
|
||||
remains as a deprecated alias for `"base32"`. Please convert your code from:
|
||||
|
||||
```nix
|
||||
builtins.convertHash { inherit hash hashAlgo; toHashFormat = "base32";}
|
||||
```
|
||||
|
||||
to
|
||||
|
||||
```nix
|
||||
builtins.convertHash { inherit hash hashAlgo; toHashFormat = "nix32";}
|
||||
```
|
Loading…
Add table
Add a link
Reference in a new issue