Check if a path is in the current working directory
Installations
npm install is-path-in-cwd
Developer Guide
Typescript
No
Module System
ESM
Min. Node Version
>=12
Node Version
16.0.0
NPM Version
7.10.0
Score
99.6
Supply Chain
68
Quality
75.5
Maintenance
100
Vulnerability
100
License
Releases
Contributors
Unable to fetch Contributors
Languages
JavaScript (76.18%)
TypeScript (23.82%)
Developer
sindresorhus
Download Statistics
Total Downloads
2,834,714,947
Last Day
973,505
Last Week
5,089,324
Last Month
18,755,056
Last Year
290,942,822
GitHub Statistics
21 Stars
20 Commits
6 Forks
6 Watching
1 Branches
5 Contributors
Bundle Size
428.00 B
Minified
287.00 B
Minified + Gzipped
Sponsor this package
Package Meta Information
Latest Version
4.0.0
Package Id
is-path-in-cwd@4.0.0
Size
1.66 kB
NPM Version
7.10.0
Node Version
16.0.0
Publised On
03 May 2021
Total Downloads
Cumulative downloads
Total Downloads
2,834,714,947
Last day
-13.4%
973,505
Compared to previous day
Last week
-4.4%
5,089,324
Compared to previous week
Last month
-17.6%
18,755,056
Compared to previous month
Last year
-19.3%
290,942,822
Compared to previous year
Daily Downloads
Weekly Downloads
Monthly Downloads
Yearly Downloads
Dependencies
1
is-path-in-cwd
Check if a path is in the current working directory
Install
$ npm install is-path-in-cwd
Usage
1import isPathInCwd from 'is-path-in-cwd'; 2 3isPathInCwd('unicorn'); 4//=> true 5 6isPathInCwd('../rainbow'); 7//=> false 8 9isPathInCwd('.'); 10//=> false
Tidelift helps make open source sustainable for maintainers while giving companies
assurances about security, maintenance, and licensing for their dependencies.
No vulnerabilities found.
Reason
security policy file detected
Details
- Info: security policy file detected: .github/security.md:1
- Info: Found linked content: .github/security.md:1
- Info: Found disclosure, vulnerability, and/or timelines in security policy: .github/security.md:1
- Info: Found text in security policy: .github/security.md:1
Reason
no dangerous workflow patterns detected
Reason
no binaries found in the repo
Reason
license file detected
Details
- Info: project has a license file: license:0
- Info: FSF or OSI recognized license: MIT License: license:0
Reason
0 existing vulnerabilities detected
Reason
Found 4/20 approved changesets -- score normalized to 2
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/main.yml:17: update your workflow using https://app.stepsecurity.io/secureworkflow/sindresorhus/is-path-in-cwd/main.yml/main?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/main.yml:18: update your workflow using https://app.stepsecurity.io/secureworkflow/sindresorhus/is-path-in-cwd/main.yml/main?enable=pin
- Warn: npmCommand not pinned by hash: .github/workflows/main.yml:22
- Info: 0 out of 2 GitHub-owned 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/main.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 'main'
Reason
SAST tool is not run on all commits -- score normalized to 0
Details
- Warn: 0 commits out of 4 are checked with a SAST tool
Score
4.2
/10
Last Scanned on 2025-01-13
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