{"id":18774209,"url":"https://github.com/leny/grunt-supervisor","last_synced_at":"2025-07-07T01:04:30.862Z","repository":{"id":14574113,"uuid":"17290288","full_name":"leny/grunt-supervisor","owner":"leny","description":"Run supervisor as a grunt task for easy configuration and integration with the rest of your workflow","archived":false,"fork":false,"pushed_at":"2021-04-29T19:58:10.000Z","size":210,"stargazers_count":7,"open_issues_count":5,"forks_count":3,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-06-22T09:43:02.006Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/leny.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE-MIT","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2014-02-28T15:31:34.000Z","updated_at":"2023-08-27T09:29:40.000Z","dependencies_parsed_at":"2022-09-11T09:41:20.019Z","dependency_job_id":null,"html_url":"https://github.com/leny/grunt-supervisor","commit_stats":null,"previous_names":[],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/leny/grunt-supervisor","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leny%2Fgrunt-supervisor","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leny%2Fgrunt-supervisor/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leny%2Fgrunt-supervisor/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leny%2Fgrunt-supervisor/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/leny","download_url":"https://codeload.github.com/leny/grunt-supervisor/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leny%2Fgrunt-supervisor/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":263996034,"owners_count":23541399,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-07T19:37:44.262Z","updated_at":"2025-07-07T01:04:30.845Z","avatar_url":"https://github.com/leny.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# grunt-supervisor\n\n![NPM version](http://img.shields.io/npm/v/grunt-supervisor.svg) ![Dependency Status](https://david-dm.org/leny/grunt-supervisor.svg) ![Downloads counter](http://img.shields.io/npm/dm/grunt-supervisor.svg)\n\n\u003e Run [supervisor](https://github.com/isaacs/node-supervisor) as a grunt task for easy configuration and integration with the rest of your workflow.\n\n* * *\n\n*This Grunt task is freely inspired from the [grunt-nodemon](https://github.com/ChrisWren/grunt-nodemon) by [Chris Wen](https://github.com/ChrisWren).*\n\n## Getting Started\nIf you haven't used grunt before, be sure to check out the [Getting Started](http://gruntjs.com/getting-started) guide, as it explains how to create a gruntfile as well as install and use grunt plugins. Once you're familiar with that process, install this plugin with this command:\n\n```shell\nnpm install grunt-supervisor --save-dev\n```\n\nThen add this line to your project's `Gruntfile.js` gruntfile:\n\n```javascript\ngrunt.loadNpmTasks( \"grunt-supervisor\" );\n```\n\n## The \"supervisor\" task\n\nIn your project's Gruntfile, add a section named `supervisor` to the data object passed into `grunt.initConfig()`.\n\n### Minimal usage\n\nThe minimal usage of **grunt-supervisor** runs with a `script` specified:\n\n```js\nsupervisor: {\n  target: {\n    script: \"index.js\"\n  }\n}\n```\n\n### Usage with all available options\n\n```js\nsupervisor: {\n  target: {\n    script: \"index.js\",\n    options: {\n      args: [ \"dev\" ]\n      watch: [ \"bin\" ],\n      ignore: [ \"test\" ],\n      pollInterval: 500,\n      extensions: [ \"js,jade\" ],\n      exec: \"node\",\n      debug: true,\n      inspect: true,\n      debugBrk: true,\n      harmony: true,\n      noRestartOn: \"exit\",\n      forceWatch: true,\n      quiet: true,\n      forceSync: true\n    }\n  }\n}\n```\n\n#### Required property\n\n##### script\nType: `String`\n\nScript that supervisor runs and restarts when changes are detected.\n\n#### Options\n\nThe following options corresponds to the available options from [supervisor](https://github.com/isaacs/node-supervisor). If you don't pass these options to the grunt tasks, the default values of supervisor will be used.\n\n##### args\nType: `Array` of `Strings`\nList of arguments to be passed to your script.\n\n##### watch\nType: `Array` of `Strings`\nList of folders or js files to watch for changes.\n\n##### ignore\nType: `Array` of `Strings`\nList of folders to ignore for changes.\n\n##### pollInterval\nType: `Number` of **milliseconds**\nHow often to poll watched files for changes.\n\n##### extensions\nType: `Array` of `Strings`\nList of file extensions to watch for changes.\n\n##### exec\nType: `String`\nThe executable that runs the specified script.\n\n##### debug\nType: `Boolean`\nStarts node with `--debug` flag.\n\n##### debugBrk\nType: `Boolean`\nStarts node with `--debug-brk` flag.\n\n##### inspect\nType: `Boolean`\nStarts node with `--inspect` flag.\n\n##### harmony\nType: `Boolean`\nStarts node with `--harmony` flag.\n\n##### noRestartOn\nType: `String`, `\"error\"` or `\"exit\"`\nDon't automatically restart the supervised program if it ends.\nSupervisor will wait for a change in the source files.\nIf \"error\", an exit code of 0 will still restart.\nIf \"exit\", no restart regardless of exit code.\n\n##### forceWatch\nType: `Boolean`\nUse fs.watch instead of fs.watchFile.\nThis may be useful if you see a high cpu load on a windows machine.\n\n##### quiet\nType: `Boolean`\nSuppress DEBUG messages\n\n##### forceSync\nType: `Boolean`\nAvoid the default `async` behavior. Set to `true` if there is another task like \"watch\" folowing this one.\n\n### Using supervisor with a `watch` task.\n\nYou can use supervisor and a `watch` task using the `forceSync` option.\n\nFor more advanced use, please consider the use of [grunt-concurrent](https://github.com/sindresorhus/grunt-concurrent) task.\n\n## Contributing\n\nIn lieu of a formal styleguide, take care to maintain the existing coding style. Add unit tests for any new or changed functionality. Lint and test your code using [Grunt](http://gruntjs.com/).\n\n### Contributors\n\n* [ajcrites](https://github.com/ajcrites)\n* [akagomez](https://github.com/akagomez)\n* [relvao](https://github.com/relvao)\n* [danielkappelle](https://github.com/danielkappelle)\n\nMany thanks to them. :)\n\n## Release History\n\n* **0.1.0**: Initial release (*28/02/14*)\n* **0.2.0**: Add `forceSync` option (*23/04/14*)\n\n## TODO\n\nWrite tests :)\n\n## License\nCopyright (c) 2014 Leny\nLicensed under the MIT license.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fleny%2Fgrunt-supervisor","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fleny%2Fgrunt-supervisor","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fleny%2Fgrunt-supervisor/lists"}