@oasis-cloud/which-one
v0.0.7
Published
List the scripts in package.json and choose one to execute
Downloads
30
Maintainers
Readme
which one
List the scripts in package.json and choose one to execute.
Read this in other languages: English | 简体中文
Install
npm install -D @oasis-cloud/which-one
Example
└─> wo
? which one › - Use arrow-keys. Return to submit.
❯ test
color
or
└─> wo c
? which one › - Use arrow-keys. Return to submit.
❯ color
demo:c
If only one script exists after filtering scripts, it is executed directly.
└─> wo color
Regular Filtering
Regular matching is filtered using global matching that ignores case.
│which-one on main
└─> wo c
? which one › - Use arrow-keys. Return to submit.
❯ color
│which-one on main
└─> wo 'd.*:c'
? which one › - Use arrow-keys. Return to submit.
❯ demo:c
Options
-r
Supports the -r option, which executes the previous script.
│which-one on main
└─> wo 'd.*:c'
? which one › - Use arrow-keys. Return to submit.
❯ demo:c
# will execute demo:c
│which-one on main
└─> wo -r