Installations
npm install fined
Developer
gulpjs
Developer Guide
Module System
CommonJS
Min. Node Version
>= 10.13.0
Typescript Support
No
Node Version
14.18.0
NPM Version
7.24.2
Statistics
12 Stars
21 Commits
6 Forks
7 Watching
2 Branches
4 Contributors
Updated on 05 Nov 2023
Languages
JavaScript (100%)
Total Downloads
Cumulative downloads
Total Downloads
811,620,512
Last day
-3%
625,595
Compared to previous day
Last week
3.3%
3,393,995
Compared to previous week
Last month
16.4%
13,581,784
Compared to previous month
Last year
5.1%
144,540,758
Compared to previous year
Daily Downloads
Weekly Downloads
Monthly Downloads
Yearly Downloads
fined
Find a file given a declaration of locations.
Usage
1var fined = require('fined'); 2 3fined({ path: 'path/to/file', extensions: ['.js', '.json'] }); 4// => { path: '/absolute/path/to/file.js', extension: '.js' } (if file exists) 5// => null (if file does not exist) 6 7var opts = { 8 name: '.app', 9 cwd: '.', 10 extensions: { 11 rc: 'default-rc-loader', 12 '.yml': 'default-yml-loader', 13 }, 14}; 15 16fined({ path: '.' }, opts); 17// => { path: '/absolute/of/cwd/.app.yml', extension: { '.yml': 'default-yml-loader' } } 18 19fined({ path: '~', extensions: { rc: 'some-special-rc-loader' } }, opts); 20// => { path: '/User/home/.apprc', extension: { 'rc': 'some-special-rc-loader' } }
API
fined(pathObj, opts) => object | null
Arguments:
-
pathObj [string | object] : a path setting for finding a file.
-
opts [object] : a plain object supplements
pathObj
.pathObj
andopts
can have same properties:- path [string] : a path string.
- name [string] : a basename.
- extensions: [string | array | object] : extensions.
- cwd: a base directory of
path
and for finding up. - findUp: [boolean] : a flag to find up.
Return:
This function returns a plain object which consists of following properties if a file exists otherwise null.
- path : an absolute path
- extension : a string or a plain object of extension.
License
MIT
No vulnerabilities found.
Reason
no binaries found in the repo
Reason
no dangerous workflow patterns detected
Reason
0 existing vulnerabilities detected
Reason
license file detected
Details
- Info: project has a license file: LICENSE:0
- Info: FSF or OSI recognized license: MIT License: LICENSE:0
Reason
security policy file detected
Details
- Info: security policy file detected: github.com/gulpjs/.github/SECURITY.md:1
- Info: Found linked content: github.com/gulpjs/.github/SECURITY.md:1
- Info: Found disclosure, vulnerability, and/or timelines in security policy: github.com/gulpjs/.github/SECURITY.md:1
- Info: Found text in security policy: github.com/gulpjs/.github/SECURITY.md:1
Reason
Found 7/20 approved changesets -- score normalized to 3
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
dependency not pinned by hash detected -- score normalized to 0
Details
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/dev.yml:19: update your workflow using https://app.stepsecurity.io/secureworkflow/gulpjs/fined/dev.yml/master?enable=pin
- Warn: third-party GitHubAction not pinned by hash: .github/workflows/dev.yml:22: update your workflow using https://app.stepsecurity.io/secureworkflow/gulpjs/fined/dev.yml/master?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/dev.yml:39: update your workflow using https://app.stepsecurity.io/secureworkflow/gulpjs/fined/dev.yml/master?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/dev.yml:42: update your workflow using https://app.stepsecurity.io/secureworkflow/gulpjs/fined/dev.yml/master?enable=pin
- Warn: third-party GitHubAction not pinned by hash: .github/workflows/dev.yml:59: update your workflow using https://app.stepsecurity.io/secureworkflow/gulpjs/fined/dev.yml/master?enable=pin
- Warn: third-party GitHubAction not pinned by hash: .github/workflows/dev.yml:72: update your workflow using https://app.stepsecurity.io/secureworkflow/gulpjs/fined/dev.yml/master?enable=pin
- Warn: third-party GitHubAction not pinned by hash: .github/workflows/release.yml:12: update your workflow using https://app.stepsecurity.io/secureworkflow/gulpjs/fined/release.yml/master?enable=pin
- Warn: npmCommand not pinned by hash: .github/workflows/dev.yml:51
- Info: 0 out of 3 GitHub-owned GitHubAction dependencies pinned
- Info: 0 out of 4 third-party GitHubAction dependencies pinned
- Info: 0 out of 1 npmCommand dependencies pinned
Reason
detected GitHub workflow tokens with excessive permissions
Details
- Warn: no topLevel permission defined: .github/workflows/dev.yml:1
- Warn: no topLevel permission defined: .github/workflows/release.yml:1
- Info: no jobLevel write permissions found
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
project is not fuzzed
Details
- Warn: no fuzzer integrations found
Reason
branch protection not enabled on development/release branches
Details
- Warn: branch protection not enabled for branch 'master'
Reason
SAST tool is not run on all commits -- score normalized to 0
Details
- Warn: 0 commits out of 9 are checked with a SAST tool
Score
4.3
/10
Last Scanned on 2024-11-18
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More