Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/npm/cli.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'node_modules/fstream-ignore/README.md')
-rw-r--r--node_modules/fstream-ignore/README.md22
1 files changed, 22 insertions, 0 deletions
diff --git a/node_modules/fstream-ignore/README.md b/node_modules/fstream-ignore/README.md
new file mode 100644
index 000000000..31170feae
--- /dev/null
+++ b/node_modules/fstream-ignore/README.md
@@ -0,0 +1,22 @@
+# fstream-ignore
+
+A fstream DirReader that filters out files that match globs in `.ignore`
+files throughout the tree, like how git ignores files based on a
+`.gitignore` file.
+
+Here's an example:
+
+```javascript
+var Ignore = require("fstream-ignore")
+Ignore({ path: __dirname
+ , ignoreFiles: [".ignore", ".gitignore"]
+ })
+ .on("child", function (c) {
+ console.error(c.path.substr(c.root.path.length + 1))
+ })
+ .pipe(tar.Pack())
+ .pipe(fs.createWriteStream("foo.tar"))
+```
+
+This will tar up the files in __dirname into `foo.tar`, ignoring
+anything matched by the globs in any .iginore or .gitignore file.