How to use the glob-stream function in glob-stream

To help you get started, we’ve selected a few glob-stream examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github microsoft / vscode-js-debug / src / common / sourceMaps / nodeSourceMapRepository.ts View on Github external
await new Promise((resolve, reject) =>
      globStream(
        [
          ...patterns.map(forceForwardSlashes),
          // Avoid reading asar files: electron patches in support for them, but
          // if we see an invalid one then it throws a synchronous error that
          // breaks glob. We don't care about asar's here, so just skip that:
          '!**/*.asar/**',
        ],
        {
          matchBase: true,
          cwd: base,
        },
      )
        .on('data', (value: globStream.Entry) =>
          todo.push(
            createMetadataForFile(fixDriveLetterAndSlashes(value.path))
              .then(parsed => parsed && onChild(parsed))
github sarahdayan / snippets.js / packages / snippets.js / src / helpers / createSnippets.ts View on Github external
transform
              })

              this.push(snippet)
            })
          }

          callback()
        })
      }
    })

    return inStream.pipe(upperStream)
  }

  const files = gs(sourceDir, { ignore })

  return transformFiles(files)
}

glob-stream

Readable streamx interface over anymatch.

MIT
Latest version published 25 days ago

Package Health Score

89 / 100
Full package analysis