Cli option for rename files to *.min.js
Open
- Dominant language
- JavaScript
- Stars
- 4.4k
- Forks
- 217
- PR merge metrics
- No merged PRs in 30d
Description
Hi, I am trying to rename files with cli npm but I can't
is there an option for rename? example file.js to file.min.js
Using wildcards with $1 output maybe?
This is my CLI chain (package.json):
```
"scripts": {
"compress": "babel --presets minify *.js --out-file $1.min.js --mangle.keepClassName --no-comments"
}
```
this ouput $1.min.js file -_-
Contributor guide
Research direction
Start by reproducing the package.json script with Babel's CLI and inspect how wildcard input and --out-file are handled. Determine the expected naming behavior for each input, then verify that the command produces corresponding .min.js files without leaving the literal $1.min.js name.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- babel, javascript
- Domain
- build-system, cli
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100