Merge pull request #121252 from NixOS/SuperSandro2000-patch-1

doc/contributing: add unnecessary string conversions
This commit is contained in:
Sandro 2021-05-17 02:40:29 +02:00 committed by GitHub
commit f66a5695b4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -169,6 +169,18 @@
})
```
- Unnecessary string conversions should be avoided. Do
```nix
rev = version;
```
instead of
```nix
rev = "${version}";
```
- Arguments should be listed in the order they are used, with the exception of `lib`, which always goes first.
- The top-level `lib` must be used in the master and 21.05 branch over its alias `stdenv.lib` as it now causes evaluation errors when aliases are disabled which is the case for ofborg.