Installations
npm install walk-up-path
Developer Guide
Typescript
Yes
Module System
ESM
Min. Node Version
20 || >=22
Node Version
20.13.1
NPM Version
10.7.0
Score
99.8
Supply Chain
75.1
Quality
76.3
Maintenance
100
Vulnerability
100
License
Releases
Unable to fetch releases
Contributors
Unable to fetch Contributors
Languages
JavaScript (70.11%)
TypeScript (17.37%)
Shell (12.52%)
Developer
isaacs
Download Statistics
Total Downloads
313,033,706
Last Day
674,815
Last Week
3,125,599
Last Month
14,053,164
Last Year
157,662,114
GitHub Statistics
10 Stars
21 Commits
2 Watching
1 Branches
1 Contributors
Package Meta Information
Latest Version
4.0.0
Package Id
walk-up-path@4.0.0
Unpacked Size
5.92 kB
Size
2.44 kB
File Count
13
NPM Version
10.7.0
Node Version
20.13.1
Publised On
08 Jul 2024
Total Downloads
Cumulative downloads
Total Downloads
313,033,706
Last day
-7.3%
674,815
Compared to previous day
Last week
-15.4%
3,125,599
Compared to previous week
Last month
3.9%
14,053,164
Compared to previous month
Last year
78.3%
157,662,114
Compared to previous year
Daily Downloads
Weekly Downloads
Monthly Downloads
Yearly Downloads
Dev Dependencies
5
walk-up-path
Given a path string, return a generator that walks up the path, emitting each dirname.
So, to get a platform-portable walk up, instead of doing something like this:
1for (let p = dirname(path); p;) { 2 3 // ... do stuff ... 4 5 const pp = dirname(p) 6 if (p === pp) 7 p = null 8 else 9 p = pp 10}
Or this:
1for (let p = dirname(path); !isRoot(p); p = dirname(p)) { 2 // ... do stuff ... 3}
You can do this:
1const { walkUpPath } = require('walk-up-path') 2for (const p of walkUpPath(path)) { 3 // ... do stuff .. 4}
API
1const { walkUpPath } = require('walk-up-path')
Give the fn a string, it'll yield all the directories walking up to the root.
No vulnerabilities found.
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: ISC License: LICENSE:0
Reason
3 existing vulnerabilities detected
Details
- Warn: Project is vulnerable to: GHSA-grv7-fg5c-xmjg
- Warn: Project is vulnerable to: GHSA-3xgq-45jj-v275
- Warn: Project is vulnerable to: GHSA-j8xg-fqg3-53r7
Reason
no SAST tool detected
Details
- Warn: no pull requests merged into dev branch
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
Found 0/21 approved changesets -- score normalized to 0
Reason
detected GitHub workflow tokens with excessive permissions
Details
- Warn: no topLevel permission defined: .github/workflows/ci.yml:1
- Warn: no topLevel permission defined: .github/workflows/isaacs-makework.yml:1
- Info: topLevel 'contents' permission set to 'read': .github/workflows/typedoc.yml:14
- Info: no jobLevel write permissions found
Reason
dependency not pinned by hash detected -- score normalized to 0
Details
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/ci.yml:28: update your workflow using https://app.stepsecurity.io/secureworkflow/isaacs/walk-up-path/ci.yml/main?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/ci.yml:31: update your workflow using https://app.stepsecurity.io/secureworkflow/isaacs/walk-up-path/ci.yml/main?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/isaacs-makework.yml:13: update your workflow using https://app.stepsecurity.io/secureworkflow/isaacs/walk-up-path/isaacs-makework.yml/main?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/isaacs-makework.yml:17: update your workflow using https://app.stepsecurity.io/secureworkflow/isaacs/walk-up-path/isaacs-makework.yml/main?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/typedoc.yml:32: update your workflow using https://app.stepsecurity.io/secureworkflow/isaacs/walk-up-path/typedoc.yml/main?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/typedoc.yml:34: update your workflow using https://app.stepsecurity.io/secureworkflow/isaacs/walk-up-path/typedoc.yml/main?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/typedoc.yml:42: update your workflow using https://app.stepsecurity.io/secureworkflow/isaacs/walk-up-path/typedoc.yml/main?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/typedoc.yml:44: update your workflow using https://app.stepsecurity.io/secureworkflow/isaacs/walk-up-path/typedoc.yml/main?enable=pin
- Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/typedoc.yml:49: update your workflow using https://app.stepsecurity.io/secureworkflow/isaacs/walk-up-path/typedoc.yml/main?enable=pin
- Warn: npmCommand not pinned by hash: .github/workflows/typedoc.yml:39
- Info: 0 out of 9 GitHub-owned GitHubAction dependencies pinned
- Info: 0 out of 1 npmCommand dependencies pinned
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
security policy file not detected
Details
- Warn: no security policy file detected
- Warn: no security file to analyze
- Warn: no security file to analyze
- Warn: no security file to analyze
Score
3.2
/10
Last Scanned on 2025-01-27
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