Repository: sharkdp/fd (language: rust)

Issue:
Double star globbing
Hello, I noticed that the `-g` option doesn't seem to support globbing with `**` like with `git grep` or the `-g` option for `rg`. Could you add something like this?

Examples:
```
git grep -l . "**/dir/file*"
rg --files -g "**/dir/file*"
```


Discussion / hints:
It does, but you need to use `-p`, `--full-path`:
```
    -p, --full-path
            By default, the search pattern is only
            matched against the filename (or directory
            name). Using this flag, the pattern is
            matched against the full path.
```

But be aware that you might need to use `**/` in the beginning because it will try to match on absolute paths.
Please let us know if you think the documentation can be improved.
Oh, I didn't know that about `-p`. I think it would be helpful if there was an example of using this option with `**` somewhere in the documentation.

Fix patch:
diff --git a/README.md b/README.md
index e75c79a83..523ba3e5e 100644
--- a/README.md
+++ b/README.md
@@ -145,6 +145,15 @@ target/debug/deps/libnum_cpus-f5ce7ef99006aa05.rlib
 To really search *all* files and directories, simply combine the hidden and ignore features to show
 everything (`-HI`).
 
+### Matching the full path
+By default, *fd* only matches the filename of each file. However, using the `--full-path` or `-p` option,
+you can match against the full path.
+
+```bash
+> fd -p -g '**/.git/config'
+> fd -p '.*/lesson-\d+/[a-z]+.(jpg|png)'
+```
+
 ### Command execution
 
 Instead of just showing the search results, you often want to *do something* with them. `fd`
diff --git a/doc/fd.1 b/doc/fd.1
index 94feaa1b4..3dfec2e42 100644
--- a/doc/fd.1
+++ b/doc/fd.1
@@ -55,6 +55,7 @@ pattern contains an uppercase character (smart case).
 .TP
 .B \-g, \-\-glob
 Perform a glob-based search instead of a regular expression search.
+If combined with the '\-\-full-path' option, '**' can be used to match multiple path components.
 .TP
 .B \-\-regex
 Perform a regular-expression based search (default). This can be used to override --glob.


Test patch: