Skip to content

Latest commit

 

History

History
40 lines (26 loc) · 1.63 KB

.verb.md

File metadata and controls

40 lines (26 loc) · 1.63 KB

Install bash 4.3 or later

I recommend using homebrew to install/upgrade bash:

$ brew upgrade bash

Why?

The initial motivation was to use this for generating the expected values for comparisons in tests. But as it turns out, this is faster than node-glob in most cases I've tested.

Moreover, this supports the majority of the feature-functionaly in node-glob, and it's more Bash-compliant since, well, it is Bash.

Edge cases

Inevitably there will be edge cases. Thus far, however, I've found that many of the edge cases that seem to be problematic are already addressed or not problematic for Bash.

Please feel free to create an issue if you find a bug or have a feature request.

Usage

var glob = require('{%= name %}');
glob(pattern[, options]);

API

{%= apidocs("index.js") %}

Options

The following options may be used with the main glob function or any other method:

  • dotglob: (or dot, for [node-glob][] compatibility) Includes filenames beginning with a . (dot) in the results of pathname expansion.
  • extglob: Enable extended pattern matching features.
  • failglob: If set, patterns that fail to match filenames during pathname expansion result in an error message.
  • globstar: Enable recursive globbing with **.
  • nocaseglob: (or nocase, for [node-glob][] compatibility) Enable case-insensitive matching in filenames when performing pathname expansion.
  • nullglob: If set, Bash allows patterns which match no files to expand to a null string, rather than themselves.