OSDN Git Service

Regular updates
[twpd/master.git] / watchman.md
1 ---
2 title: Watchman
3 layout: 2017/sheet
4 updated: 2017-10-18
5 weight: -1
6 keywords:
7 - "watchman watch ~/src"
8 - "watchman watch-list"
9 - "watchman -- trigger ~/rsc remake '*.js' -- make "
10 ---
11
12 ### Getting started
13
14 ```bash
15 watchman watch ./src
16 ```
17
18 Adds `./src` to the watch list.
19
20 ```bash
21 watchman -- trigger ./src retest '*.js' -- npm test
22 ```
23
24 Adds a trigger called `retest` to run `npm test` every time `*.js` changes in `./src`.
25
26 ### Watching
27
28 ```
29 watchman watch ~/src
30 watchman watch-list
31 watchman watch-del ~/src
32 ```
33
34 ## Also see
35
36  * [Documentation](https://facebook.github.io/watchman/docs/install.html) _(facebook.github.io)_