
Security News
The Hidden Blast Radius of the Axios Compromise
The Axios compromise shows how time-dependent dependency resolution makes exposure harder to detect and contain.
npm i -D fsdir
import { eachFile } from 'fsdir/eachFile'
eachFile('{,**/}* ; !{,**/}*.sass', filepath => {
console.log(`found file: ${filepath}`)
})
eachFile(['{,**/}*', '!{,**/}*.sass'], filepath => {
console.log(`found file: ${filepath}`)
})
import WatchDir from 'fsdir/WatchDir'
new WatchDir('./src')
.when('{,**/}* ; !{,**/}*.sass', filepath => {
console.log(`${filepath} file has changed`)
})
.when('{,**/}*.sass', filepath => {
console.log('sass files changed')
})
.run(() => {
console.log('all when detected has finished')
})
npx fsdir -d ./src \
--each '{,**/}*.sass' 'sass ${FILE_PATH} -o ${FILE_DIR}${FILE_NAME}.css'
npx fsdir -d ./src \
--watch '{,**/}* ; !{,**/}*.sass' 'echo "file ${FILE_PATH} has changed"' \
--watch '{,**/}*.sass' 'make css' \
--after-watch 'echo "any watch has matched and all have finished"'
These are the environment variables injected to each command:
┌────────────────────────────────────────────────────────┐
│ FILE_CWDPATH │
├─────────────────────────────────┬──────────────────────┤
│ FILE_CWDDIR │ FILE_BASE │
├────────────┬────────────────────┴──────────────────────┤
│ │ FILE_PATH │
│ FILE_CWD ├────────────────────┬───────────┬──────────┤
│ │ FILE_DIR │ FILE_NAME │ FILE_EXT │
│ │ │ │ │
" src / component/styles / component .css "
└────────────┴────────────────────┴───────────┴──────────┘
Also: `FILE_ROOTPATH` is filepath from system root
FAQs
CLI tool for running commands on reveral files
We found that fsdir demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer 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
The Axios compromise shows how time-dependent dependency resolution makes exposure harder to detect and contain.

Research
A supply chain attack on Axios introduced a malicious dependency, plain-crypto-js@4.2.1, published minutes earlier and absent from the project’s GitHub releases.

Research
Malicious versions of the Telnyx Python SDK on PyPI delivered credential-stealing malware via a multi-stage supply chain attack.