Fossil SCM

globs.md: clarified that globs apply to the whole dir/filename combination without any awareness/special treatment of the directory part, as suggested in [forum:6637b92a6a17a6bc | forum post 6637b92a6a17a6bc].

stephan 2022-02-26 01:36 trunk
Commit d862cb71d6266449f12b64d32e3819aa4f9ca2e9be5cbca217eae46614bdd08d
1 file changed +6 -1
+6 -1
--- www/globs.md
+++ www/globs.md
@@ -2,11 +2,16 @@
22
33
44
A [glob pattern][glob] is a text expression that matches one or more
55
file names using wild cards familiar to most users of a command line.
66
For example, `*` is a glob that matches any name at all and
7
-`Readme.txt` is a glob that matches exactly one file.
7
+`Readme.txt` is a glob that matches exactly one file. For purposes of
8
+Fossil's globs, a file name with a directory prefix is "just a string"
9
+and the globs do not apply any special meaning to the directory part
10
+of the name. Thus the glob `*` matches any name, including any
11
+directory prefix, and `*/*` matches a name with _one or more_
12
+directory components.
813
914
A glob should not be confused with a [regular expression][regexp] (RE),
1015
even though they use some of the same special characters for similar
1116
purposes, because [they are not fully compatible][greinc] pattern
1217
matching languages. Fossil uses globs when matching file names with the
1318
--- www/globs.md
+++ www/globs.md
@@ -2,11 +2,16 @@
2
3
4 A [glob pattern][glob] is a text expression that matches one or more
5 file names using wild cards familiar to most users of a command line.
6 For example, `*` is a glob that matches any name at all and
7 `Readme.txt` is a glob that matches exactly one file.
 
 
 
 
 
8
9 A glob should not be confused with a [regular expression][regexp] (RE),
10 even though they use some of the same special characters for similar
11 purposes, because [they are not fully compatible][greinc] pattern
12 matching languages. Fossil uses globs when matching file names with the
13
--- www/globs.md
+++ www/globs.md
@@ -2,11 +2,16 @@
2
3
4 A [glob pattern][glob] is a text expression that matches one or more
5 file names using wild cards familiar to most users of a command line.
6 For example, `*` is a glob that matches any name at all and
7 `Readme.txt` is a glob that matches exactly one file. For purposes of
8 Fossil's globs, a file name with a directory prefix is "just a string"
9 and the globs do not apply any special meaning to the directory part
10 of the name. Thus the glob `*` matches any name, including any
11 directory prefix, and `*/*` matches a name with _one or more_
12 directory components.
13
14 A glob should not be confused with a [regular expression][regexp] (RE),
15 even though they use some of the same special characters for similar
16 purposes, because [they are not fully compatible][greinc] pattern
17 matching languages. Fossil uses globs when matching file names with the
18

Keyboard Shortcuts

Open search /
Next entry (timeline) j
Previous entry (timeline) k
Open focused entry Enter
Show this help ?
Toggle theme Top nav button