Comments (5)
On the other hand if you want to press up to get to runrun again, it will be annoying that it's not in the user history.
So I guess implementing your own history inside runrun sounds like the best solution to me.
from runrun-cli.
Can you share a flow of events where this is useful?
As it takes time to find a command in history, perhaps it's just as easy to run runrun
to execute what you want.
One thing I can think of is running an npm script with extra arguments (not yet supported).
That would be useful in command history.
@elektronik2k5 mentioned npm-quick-run, which has a way to run scripts with few characters, but the interactive mode won't add to command history either (I think).
from runrun-cli.
After using runrun
for a while, I've started experiencing what you were talking about...
Running a script like lint:eslint
through runrun
and then wanting to run it again by pressing the Up arrow key.
So... if it's possible, should definitely push the command to the command line history.
Note to self:
ntl
has some solutions without touching the history:
https://github.com/ruyadorno/ntl#arrows_counterclockwise-repeat-the-last-ran-task
from runrun-cli.
@zoharyzgiaev Let's move forward with this...
Similar to this package:
https://github.com/ruyadorno/lru-cache-fs/blob/master/index.js
We don't need lru-cache, let's just save files with latest used script name.
For each CWD we'll have a file with just a string (e.g. 'lint-eslint').
Let's add fs-extra and make sure to use env-paths.
Also we now have an rr
alias for runrun
so the last run should be with rrr
.
This is set in package.json
under bin
.
from runrun-cli.
@adamkleingit Good news, it's live! 😎.
Done in #13
Read the v1.2.0 Release Notes
Would appreciate feedback.
from runrun-cli.
Related Issues (20)
- Alias `runrun` with `rr`
- UX Suggestion: Reset selected choice on search updates HOT 1
- UpdateNotifier: Add a link to the changelog
- Consider adding executed commands to shell history
- Show an error if `package.json` is not found.
- Hoist "Recently Used" scripts to the top?
- Support passing custom args when using `rrr`
- Auto Changelog
- Consider using clipanion
- Update text on script exit code other than 0
- Feature request: vim j/k mode HOT 3
- Consider a nicer `--help` formatting
- Add a flag for `rrr` to see the command that would run
- Support quick run with fuzzy match
- Add proper Fuzzy Search HOT 1
- Use all available window space instead of the default limit
- Take ideas from similar projects
- Add this project to `awesome-npm-scripts` HOT 1
- Should be able to run `rr` instead of `runrun` HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from runrun-cli.