Code Monkey home page Code Monkey logo

npm-quick-run's People

Contributors

bahmutov avatar hail2u avatar jakxz avatar jihchi avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

npm-quick-run's Issues

Colors lost

image

I guess that using inherit in stdio option of child_process.spawn fixes this.

Describe benefits

  • cross platform
  • short command syntax - most commands are 3 letters (2 for "nr" and 1 for the first letter of the script label)
  • filters verbose error output from NPM

Filter NPM error output but by line

Currently does not show error output from npm that has npm ERR! lines, but because it gets an chunk of the output with npm first, it prints it before getting the complete npm ERR!

Need to find a stream module that buffers output into lines

Handle better a missing package.json

Currently throws an exception

$ nr
[email protected]
 - Quickly run NPM script by prefix without typing the full name
USE: nrun <npm script prefix> <script arguments>
    "nr t" === "nrun t" === "npm test"
    "nr m -w" probably will find "npm run mocha -- --w"
module.js:339
    throw err;
    ^
Error: Cannot find module '/git/package.json'

Add fuzzy search along with of prefix

Prefix is good but not when you have long command, command:fix, command:beta, command:dev then it fails.

So I wish to add fuzzy search; many JS library already implement it.

Return exact match

Sometimes there is exact match and there are other prefixes. For example

"test": "...",
"test-foo": "..."

nr test should run "test" script

Print the script contents too?

Right now when printing all scripts pints just names. Maybe if printing on separate lines should print the script command text too?

Add running scripts registered in the .bin folder

To avoid using global scripts completely.
For example, imagine we install pm2 as a local dev dependency

npm i -D pm2
// how to run pm2?
node node_modules/.bin/pm2
// could be much better to run
nr pm2

add fuzzy search stopper

For example if script are command, command:dev we cannot run command without full name.

It would be nice to add . to mean "no more words" and be able to run nr c.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.