Fossil SCM
Replace []] example with [][] because a single-character character class is not terribly useful whereas the latter demonstrates the same concept as well as the visibly unusual way to match either bracket. Add example showing how to match a ^ character as well as ], further reinforcing the above.
Commit
541e32498932ce747aa778f1fd24dbdd654becb3c70ddd794cf5bc6a9336df94
Parent
b96f86c607f9a0e…
1 file changed
+2
-1
+2
-1
| --- www/globs.md | ||
| +++ www/globs.md | ||
| @@ -41,12 +41,13 @@ | ||
| 41 | 41 | |
| 42 | 42 | Some examples: |
| 43 | 43 | |
| 44 | 44 | [a-d] Matches any one of 'a', 'b', 'c', or 'd' |
| 45 | 45 | [a-] Matches either 'a' or '-' |
| 46 | - []] Matches exactly one ']' character | |
| 46 | + [][] Matches either '[' or ']' | |
| 47 | 47 | [^]] Matches exactly one character other than ']' |
| 48 | + []^] Matches either ']' or '^' | |
| 48 | 49 | |
| 49 | 50 | The glob is compared to the canonical name of the file in the checkout |
| 50 | 51 | tree, and must match the entire name to be considered a match. |
| 51 | 52 | |
| 52 | 53 | A list of GLOBs is simply one or more GLOBs separated by whitespace or |
| 53 | 54 |
| --- www/globs.md | |
| +++ www/globs.md | |
| @@ -41,12 +41,13 @@ | |
| 41 | |
| 42 | Some examples: |
| 43 | |
| 44 | [a-d] Matches any one of 'a', 'b', 'c', or 'd' |
| 45 | [a-] Matches either 'a' or '-' |
| 46 | []] Matches exactly one ']' character |
| 47 | [^]] Matches exactly one character other than ']' |
| 48 | |
| 49 | The glob is compared to the canonical name of the file in the checkout |
| 50 | tree, and must match the entire name to be considered a match. |
| 51 | |
| 52 | A list of GLOBs is simply one or more GLOBs separated by whitespace or |
| 53 |
| --- www/globs.md | |
| +++ www/globs.md | |
| @@ -41,12 +41,13 @@ | |
| 41 | |
| 42 | Some examples: |
| 43 | |
| 44 | [a-d] Matches any one of 'a', 'b', 'c', or 'd' |
| 45 | [a-] Matches either 'a' or '-' |
| 46 | [][] Matches either '[' or ']' |
| 47 | [^]] Matches exactly one character other than ']' |
| 48 | []^] Matches either ']' or '^' |
| 49 | |
| 50 | The glob is compared to the canonical name of the file in the checkout |
| 51 | tree, and must match the entire name to be considered a match. |
| 52 | |
| 53 | A list of GLOBs is simply one or more GLOBs separated by whitespace or |
| 54 |