Security News
Fluent Assertions Faces Backlash After Abandoning Open Source Licensing
Fluent Assertions is facing backlash after dropping the Apache license for a commercial model, leaving users blindsided and questioning contributor rights.
resolve-file
Advanced tools
Resolve an absolute file path from local directories, local node_modules or global node_modules.
Resolve an absolute file path from local directories, local node_modules or global node_modules.
Install with npm:
$ npm install resolve-file --save
var resolveFile = require('resolve-file');
Resolve the path to a file located in one of the following places:
'./index.js'
)'/usr/something.rc'
)'cwd'
)'cwd/LICENSE'
)'~/.npmrc'
)Params
name
{String}: Filename to resolveoptions
{Object}: Additional options to specify cwd
returns
{String}: Resolved filepath
if foundExample
var fp = resolve('./index.js')
//=> /path/to/resolve-file/index.js
Resolve the path to a file located in one of the following places:
'./index.js'
)'/usr/something.rc'
)'cwd'
)'cwd/LICENSE'
)'~/.npmrc'
)Params
name
{String}: Filename to resolveoptions
{Object}: Additional options to specify cwd
returns
{Object}: File object with resolved path
if found.Example
var file = resolve.file('./index.js')
//=> {
//=> cwd: '/path/to/resolve-file',
//=> path: '/path/to/resolve-file/index.js'
//=> }
You might also be interested in these projects:
This document was generated by verb, please don't edit directly. Any changes to the readme must be made in .verb.md. See Building Docs.
Pull requests and stars are always welcome. For bugs and feature requests, please create an issue.
Generate readme and API documentation with verb:
$ npm install -g verb verb-readme-generator && verb
Or, if verb is installed globally:
$ verb
Install dev dependencies:
$ npm install -d && npm test
Brian Woodward
Copyright © 2016, Brian Woodward. Released under the MIT license.
This file was generated by verb, v0.9.0, on June 06, 2016.
FAQs
Resolve an absolute file path from local directories, local node_modules or global node_modules.
We found that resolve-file demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 2 open source maintainers collaborating on the project.
Did you know?
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.
Security News
Fluent Assertions is facing backlash after dropping the Apache license for a commercial model, leaving users blindsided and questioning contributor rights.
Research
Security News
Socket researchers uncover the risks of a malicious Python package targeting Discord developers.
Security News
The UK is proposing a bold ban on ransomware payments by public entities to disrupt cybercrime, protect critical services, and lead global cybersecurity efforts.