From c34cc5e488b7baf7dcc1944c72fdceaa6affb55a Mon Sep 17 00:00:00 2001 From: Dimitris Apostolou Date: Wed, 3 Nov 2021 18:11:20 +0200 Subject: Fix typos --- doc/manual/src/expressions/advanced-attributes.md | 2 +- doc/manual/src/expressions/expression-syntax.md | 2 +- doc/manual/src/expressions/language-values.md | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) (limited to 'doc/manual/src/expressions') diff --git a/doc/manual/src/expressions/advanced-attributes.md b/doc/manual/src/expressions/advanced-attributes.md index 5b208df67..000595815 100644 --- a/doc/manual/src/expressions/advanced-attributes.md +++ b/doc/manual/src/expressions/advanced-attributes.md @@ -237,7 +237,7 @@ Derivations can declare some infrequently used optional attributes. - `preferLocalBuild`\ If this attribute is set to `true` and [distributed building is enabled](../advanced-topics/distributed-builds.md), then, if - possible, the derivaton will be built locally instead of forwarded + possible, the derivation will be built locally instead of forwarded to a remote machine. This is appropriate for trivial builders where the cost of doing a download or remote build would exceed the cost of building locally. diff --git a/doc/manual/src/expressions/expression-syntax.md b/doc/manual/src/expressions/expression-syntax.md index 2a1306e32..6b93e692c 100644 --- a/doc/manual/src/expressions/expression-syntax.md +++ b/doc/manual/src/expressions/expression-syntax.md @@ -26,7 +26,7 @@ elements (referenced from the figure by number): called with three arguments: `stdenv`, `fetchurl`, and `perl`. They are needed to build Hello, but we don't know how to build them here; that's why they are function arguments. `stdenv` is a package that - is used by almost all Nix Packages packages; it provides a + is used by almost all Nix Packages; it provides a “standard” environment consisting of the things you would expect in a basic Unix environment: a C/C++ compiler (GCC, to be precise), the Bash shell, fundamental Unix tools such as `cp`, `grep`, `tar`, diff --git a/doc/manual/src/expressions/language-values.md b/doc/manual/src/expressions/language-values.md index 28fa23b58..75ae9f2eb 100644 --- a/doc/manual/src/expressions/language-values.md +++ b/doc/manual/src/expressions/language-values.md @@ -64,7 +64,7 @@ Nix has the following basic data types: the start of each line. To be precise, it strips from each line a number of spaces equal to the minimal indentation of the string as a whole (disregarding the indentation of empty lines). For instance, - the first and second line are indented two space, while the third + the first and second line are indented two spaces, while the third line is indented four spaces. Thus, two spaces are stripped from each line, so the resulting string is -- cgit v1.2.3 From eae54f2d5208427080c8793d6c88db8550337d77 Mon Sep 17 00:00:00 2001 From: Kevin Amado Date: Sat, 13 Nov 2021 22:28:20 -0500 Subject: fix many doc typos --- doc/manual/src/expressions/builtins-prefix.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'doc/manual/src/expressions') diff --git a/doc/manual/src/expressions/builtins-prefix.md b/doc/manual/src/expressions/builtins-prefix.md index 87127de2a..c631a8453 100644 --- a/doc/manual/src/expressions/builtins-prefix.md +++ b/doc/manual/src/expressions/builtins-prefix.md @@ -12,5 +12,5 @@ For instance, `derivation` is also available as `builtins.derivation`.
derivation attrs; builtins.derivation attrs
-

derivation in described in +

derivation is described in its own section.

-- cgit v1.2.3 From ca4d8ce9e22ef04687b1516c9472a5d3f82e056b Mon Sep 17 00:00:00 2001 From: Jan Tojnar Date: Wed, 17 Nov 2021 16:30:39 +0100 Subject: doc: De-emphasize nix-env without -A The manual uses `nix-env -i` without `-A` prominently, teaching a bad practice to newcomers. --- doc/manual/src/expressions/simple-building-testing.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'doc/manual/src/expressions') diff --git a/doc/manual/src/expressions/simple-building-testing.md b/doc/manual/src/expressions/simple-building-testing.md index 6f730a936..7f0d8f841 100644 --- a/doc/manual/src/expressions/simple-building-testing.md +++ b/doc/manual/src/expressions/simple-building-testing.md @@ -1,6 +1,6 @@ # Building and Testing -You can now try to build Hello. Of course, you could do `nix-env -i +You can now try to build Hello. Of course, you could do `nix-env -f . -iA hello`, but you may not want to install a possibly broken package just yet. The best way to test the package is by using the command `nix-build`, which builds a Nix expression and creates a symlink named -- cgit v1.2.3 From e1192116d357fd8346ebeed64de25730e47b4147 Mon Sep 17 00:00:00 2001 From: Lorenz Leutgeb Date: Thu, 18 Nov 2021 15:08:01 +0100 Subject: doc: Fix escape for operator "logical or" See https://matrix.to/#/!KqkRjyTEzAGRiZFBYT:nixos.org/$hhMb6AdRIXfRkv_LsNsiQJuch7AQ_b6szr4tfawFy-4 --- doc/manual/src/expressions/language-operators.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'doc/manual/src/expressions') diff --git a/doc/manual/src/expressions/language-operators.md b/doc/manual/src/expressions/language-operators.md index b7fd6f4c6..6ab319039 100644 --- a/doc/manual/src/expressions/language-operators.md +++ b/doc/manual/src/expressions/language-operators.md @@ -24,5 +24,5 @@ order of precedence (from strongest to weakest binding). | Equality | *e1* `==` *e2* | none | Equality. | 11 | | Inequality | *e1* `!=` *e2* | none | Inequality. | 11 | | Logical AND | *e1* `&&` *e2* | left | Logical AND. | 12 | -| Logical OR | *e1* `\|\|` *e2* | left | Logical OR. | 13 | -| Logical Implication | *e1* `->` *e2* | none | Logical implication (equivalent to `!e1 \|\| e2`). | 14 | +| Logical OR | *e1* || *e2* | left | Logical OR. | 13 | +| Logical Implication | *e1* `->` *e2* | none | Logical implication (equivalent to !e1 || e2). | 14 | -- cgit v1.2.3 From 09471d2680292af48b2788108de56a8da755d661 Mon Sep 17 00:00:00 2001 From: Silvan Mosberger Date: Mon, 22 Nov 2021 23:56:40 +0100 Subject: Make lists be comparable Makes lists comparable using lexicographic comparison. Increments builtins.langVersion in order for this change to be detectable --- doc/manual/src/expressions/language-operators.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'doc/manual/src/expressions') diff --git a/doc/manual/src/expressions/language-operators.md b/doc/manual/src/expressions/language-operators.md index 6ab319039..268b44f4c 100644 --- a/doc/manual/src/expressions/language-operators.md +++ b/doc/manual/src/expressions/language-operators.md @@ -17,10 +17,10 @@ order of precedence (from strongest to weakest binding). | String Concatenation | *string1* `+` *string2* | left | String concatenation. | 7 | | Not | `!` *e* | none | Boolean negation. | 8 | | Update | *e1* `//` *e2* | right | Return a set consisting of the attributes in *e1* and *e2* (with the latter taking precedence over the former in case of equally named attributes). | 9 | -| Less Than | *e1* `<` *e2*, | none | Arithmetic comparison. | 10 | -| Less Than or Equal To | *e1* `<=` *e2* | none | Arithmetic comparison. | 10 | -| Greater Than | *e1* `>` *e2* | none | Arithmetic comparison. | 10 | -| Greater Than or Equal To | *e1* `>=` *e2* | none | Arithmetic comparison. | 10 | +| Less Than | *e1* `<` *e2*, | none | Arithmetic/lexicographic comparison. | 10 | +| Less Than or Equal To | *e1* `<=` *e2* | none | Arithmetic/lexicographic comparison. | 10 | +| Greater Than | *e1* `>` *e2* | none | Arithmetic/lexicographic comparison. | 10 | +| Greater Than or Equal To | *e1* `>=` *e2* | none | Arithmetic/lexicographic comparison. | 10 | | Equality | *e1* `==` *e2* | none | Equality. | 11 | | Inequality | *e1* `!=` *e2* | none | Inequality. | 11 | | Logical AND | *e1* `&&` *e2* | left | Logical AND. | 12 | -- cgit v1.2.3 From 89b4df8d9271303416ac7ce6d86f9be58f40540d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Theodor=20Ren=C3=A9=20Carlsen?= <36312737+TheodorRene@users.noreply.github.com> Date: Tue, 11 Jan 2022 17:01:43 +0100 Subject: Add link to explanation when introducing a new operator The logical implication operator is included in this section but never explained. It might stump new readers with a pretty uncommon operator, and it's never referenced explicitly. --- doc/manual/src/expressions/language-constructs.md | 1 + 1 file changed, 1 insertion(+) (limited to 'doc/manual/src/expressions') diff --git a/doc/manual/src/expressions/language-constructs.md b/doc/manual/src/expressions/language-constructs.md index cb0169239..c406b6910 100644 --- a/doc/manual/src/expressions/language-constructs.md +++ b/doc/manual/src/expressions/language-constructs.md @@ -276,6 +276,7 @@ stdenv.mkDerivation { ... } ``` +("->" is a boolean operation known as [logical implication](https://en.wikipedia.org/wiki/Truth_table#Logical_implication)) The points of interest are: -- cgit v1.2.3 From 5e9653c3701eddf86312b534d7e8340c0857e84b Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Thu, 13 Jan 2022 14:33:09 +0100 Subject: Tweak --- doc/manual/src/expressions/language-constructs.md | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'doc/manual/src/expressions') diff --git a/doc/manual/src/expressions/language-constructs.md b/doc/manual/src/expressions/language-constructs.md index c406b6910..1c01f2cc7 100644 --- a/doc/manual/src/expressions/language-constructs.md +++ b/doc/manual/src/expressions/language-constructs.md @@ -276,7 +276,6 @@ stdenv.mkDerivation { ... } ``` -("->" is a boolean operation known as [logical implication](https://en.wikipedia.org/wiki/Truth_table#Logical_implication)) The points of interest are: @@ -285,6 +284,10 @@ The points of interest are: function is called with the `localServer` argument set to `true` but the `db4` argument set to `null`, then the evaluation fails. + Note that `->` is the [logical + implication](https://en.wikipedia.org/wiki/Truth_table#Logical_implication) + Boolean operation. + 2. This is a more subtle condition: if Subversion is built with Apache (`httpServer`) support, then the Expat library (an XML library) used by Subversion should be same as the one used by Apache. This is -- cgit v1.2.3