{"_attachments":{},"_id":"nodemon","_rev":"1703-61f14760b677e08f51141705","author":{"name":"Remy Sharp","url":"https://github.com/remy"},"description":"Simple monitor script for use during development of a Node.js app.","dist-tags":{"debug":"2.0.14-alpha.1","debug-1268":"1.15.2-alpha.2","latest":"3.1.0"},"license":"MIT","maintainers":[{"name":"remy","email":"remy@leftlogic.com"}],"name":"nodemon","readme":"
\n\n# nodemon\n\nnodemon is a tool that helps develop Node.js based applications by automatically restarting the node application when file changes in the directory are detected.\n\nnodemon does **not** require *any* additional changes to your code or method of development. nodemon is a replacement wrapper for `node`. To use `nodemon`, replace the word `node` on the command line when executing your script.\n\n[![NPM version](https://badge.fury.io/js/nodemon.svg)](https://npmjs.org/package/nodemon)\n[![Backers on Open Collective](https://opencollective.com/nodemon/backers/badge.svg)](#backers) [![Sponsors on Open Collective](https://opencollective.com/nodemon/sponsors/badge.svg)](#sponsors)\n\n# Installation\n\nEither through cloning with git or by using [npm](http://npmjs.org) (the recommended way):\n\n```bash\nnpm install -g nodemon # or using yarn: yarn global add nodemon\n```\n\nAnd nodemon will be installed globally to your system path.\n\nYou can also install nodemon as a development dependency:\n\n```bash\nnpm install --save-dev nodemon # or using yarn: yarn add nodemon -D\n```\n\nWith a local installation, nodemon will not be available in your system path or you can't use it directly from the command line. Instead, the local installation of nodemon can be run by calling it from within an npm script (such as `npm start`) or using `npx nodemon`.\n\n# Usage\n\nnodemon wraps your application, so you can pass all the arguments you would normally pass to your app:\n\n```bash\nnodemon [your node app]\n```\n\nFor CLI options, use the `-h` (or `--help`) argument:\n\n```bash\nnodemon -h\n```\n\nUsing nodemon is simple, if my application accepted a host and port as the arguments, I would start it as so:\n\n```bash\nnodemon ./server.js localhost 8080\n```\n\nAny output from this script is prefixed with `[nodemon]`, otherwise all output from your application, errors included, will be echoed out as expected.\n\nYou can also pass the `inspect` flag to node through the command line as you would normally:\n\n```bash\nnodemon --inspect ./server.js 80\n```\n\nIf you have a `package.json` file for your app, you can omit the main script entirely and nodemon will read the `package.json` for the `main` property and use that value as the app ([ref](https://github.com/remy/nodemon/issues/14)).\n\nnodemon will also search for the `scripts.start` property in `package.json` (as of nodemon 1.1.x).\n\nAlso check out the [FAQ](https://github.com/remy/nodemon/blob/master/faq.md) or [issues](https://github.com/remy/nodemon/issues) for nodemon.\n\n## Automatic re-running\n\nnodemon was originally written to restart hanging processes such as web servers, but now supports apps that cleanly exit. If your script exits cleanly, nodemon will continue to monitor the directory (or directories) and restart the script if there are any changes.\n\n## Manual restarting\n\nWhilst nodemon is running, if you need to manually restart your application, instead of stopping and restart nodemon, you can type `rs` with a carriage return, and nodemon will restart your process.\n\n## Config files\n\nnodemon supports local and global configuration files. These are usually named `nodemon.json` and can be located in the current working directory or in your home directory. An alternative local configuration file can be specified with the `--config