Watch for file changes and then execute command
npm install @lassehaslev/executorbash
Install project globaly
npm install -g @lassehaslev/executorInstall executor per project
npm install @lassehaslev/executor --save-dev
`Usage
$3
`bash
Doc
executor ""
[--run-on-first=true]
[--watch="*/"]
[--ignore=""] -- [{Custom arguments added to the }]
Example
executor './vendor/bin/phpunit' --watch='*/.php' --ignore='/node_modules|\.git|vendor/'Custom arguments
executor './vendor/bin/phpunit' --watch='*/.php' -- --filter="CustomTest"
`$3
package.json
`json
{
"scripts": {
"my-script": "executor '' [options]",
}
}
`
Now you can run the command `npm run my-script` from command line.If you run per project and not in a npm script the command is
`./node_modules/.bin/executor`.> Pro tip: use
npm run my-script -- --your --command-option="yey" to add options to your command.$3
I use this project to run Test Driven Development for my Laravel applications.Check out this Laracasts thread for more information.
Add
tdd script to projects package.json
`json
{
"scripts": {
"tdd": "executor './vendor/bin/phpunit --color=always' --watch='*/.php' --ignore='node_modules/' --ignore='vendor/'"
}
}
`Then run
npm run tdd from your projects folder.> Pro tip: use
npm run tdd -- --filter="awesome_test" to filter your phpunit tests.Contributing
Follow these steps to contribute to project. 1. Fork the repo on GitHub
2. Clone the project to your own machine
3. Commit changes to your own branch
4. Push your work back up to your fork
5. Submit a Pull request so that we can review your changes
Development
`bash
link to local command line
npm linkcompile to es6
npm run devWhen you are finished unlink local command
npm unlink
``