-
-
Save benjaminparnell/cb2a585eb930dc9311a8 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env node | |
| var chokadir = require('chokidar') | |
| var exec = require('child_process').exec | |
| chokadir.watch('./src').on('change', function () { | |
| console.log('Got a change, running lein run') | |
| exec('lein run', { cwd: process.cwd() }, function (err, stdout, stderr) { | |
| if (err || stderr) { | |
| throw err || stderr | |
| } | |
| }) | |
| }) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment