Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

find-file-paths

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

find-file-paths

Small utility to recursively search for files based on an array of search & exclude patterns which returns an array of absolute paths for the files found.

  • 0.0.0
  • latest
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

find-file-paths

Small utility to recursively search for files based on an array of search & exclude patterns which returns an array of absolute paths for the files found.

Install

npm install find-file-paths

Usage

findPaths = require 'find-file-paths'

startDir = process.cwd() + '/test'

greedy = true

searchPatterns = [
  'ui-tests/'         # Matches all files in "#{startDir}/ui-tests/*"
  'load-tests/login'  # Matches all files in "#{startDir}/load-tests/login*"
  '*smoke*'           # Matches all files in "#{startDir}/*" with "smoke" in the name
]

excludePatterns = [
  'unit/'     # Excludes all files in "#{startDir}/unit/*"
  '*.broken'  # Excludes all files with ".broken" in the name
]

allAbsoluteFilePaths = findPaths searchPatterns, excludePatterns, greedy, startDir

More detailed parameter explanations can be found in the code.

Keywords

FAQs

Package last updated on 05 Jun 2014

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc