diff options
author | Sandro <sandro.jaeckel@gmail.com> | 2021-05-17 02:40:29 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-05-17 02:40:29 +0200 |
commit | f66a5695b45afdb95963d6fe5fe445c43a6c1acb (patch) | |
tree | fe93497d90f1fb892617374462290c8a9f39bdb6 /doc | |
parent | 9bc04854e191812f0f4907813d04d7c141a844e5 (diff) | |
parent | 08ab1d9572735f9a1218ffaa1ade0ac3e9b60167 (diff) | |
download | nixpkgs-f66a5695b45afdb95963d6fe5fe445c43a6c1acb.tar nixpkgs-f66a5695b45afdb95963d6fe5fe445c43a6c1acb.tar.gz nixpkgs-f66a5695b45afdb95963d6fe5fe445c43a6c1acb.tar.bz2 nixpkgs-f66a5695b45afdb95963d6fe5fe445c43a6c1acb.tar.lz nixpkgs-f66a5695b45afdb95963d6fe5fe445c43a6c1acb.tar.xz nixpkgs-f66a5695b45afdb95963d6fe5fe445c43a6c1acb.tar.zst nixpkgs-f66a5695b45afdb95963d6fe5fe445c43a6c1acb.zip |
Merge pull request #121252 from NixOS/SuperSandro2000-patch-1
doc/contributing: add unnecessary string conversions
Diffstat (limited to 'doc')
-rw-r--r-- | doc/contributing/coding-conventions.chapter.md | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/doc/contributing/coding-conventions.chapter.md b/doc/contributing/coding-conventions.chapter.md index e12db53ee33..6076460b893 100644 --- a/doc/contributing/coding-conventions.chapter.md +++ b/doc/contributing/coding-conventions.chapter.md @@ -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. |