Skip to content

Commit 4fec6c1

Browse files
committed
Update readme about local scripts
1 parent 57b2346 commit 4fec6c1

File tree

1 file changed

+11
-1
lines changed

1 file changed

+11
-1
lines changed

README.md

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,17 @@ Configuration should be an object where each key is a file or directory mathed b
7070

7171
## What commands are supported?
7272

73-
For now, only globally available commands are allowed. PRs welcome so local scripts are used first.
73+
Supported are any executables installed locally or globally via `npm` or Yarn as well as any executable from your `$PATH`.
74+
75+
> Using globally installed scripts is discouraged, since run-if-changed may not work for someone who doesn't have it installed.
76+
77+
`run-if-changed` is using [npm-which](https://github.com/timoxley/npm-which) to locate locally installed scripts. So in your `.run-if-changedrc` you can write:
78+
79+
```json
80+
{
81+
"src": "webpack"
82+
}
83+
```
7484

7585
Sequences of commands are supported. Pass an array of commands instead of a single one and they will run sequentially.
7686

0 commit comments

Comments
 (0)