diff options
author | Kat Marchán <kzm@sykosomatic.org> | 2016-10-20 00:16:45 +0300 |
---|---|---|
committer | Kat Marchán <kzm@sykosomatic.org> | 2016-10-20 03:25:04 +0300 |
commit | c27412bb9fc7b09f7707c7d9ad23128959ae1abc (patch) | |
tree | f6121d775314f2af36a8972718d81b6a8dcdabd4 /doc | |
parent | c12bbf8c5a5dff24a191b66ac638f552bfb76601 (diff) |
doc: replace prepublish with prepare in package.json docs
PR-URL: https://github.com/npm/npm/pull/14290
Credit: @zkat
Reviewed-By: @othiym23
Diffstat (limited to 'doc')
-rw-r--r-- | doc/files/package.json.md | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/doc/files/package.json.md b/doc/files/package.json.md index 4d8538500..1c3b0edaa 100644 --- a/doc/files/package.json.md +++ b/doc/files/package.json.md @@ -517,7 +517,7 @@ from the root of a package, and can be managed like any other npm configuration param. See `npm-config(7)` for more on the topic. For build steps that are not platform-specific, such as compiling -CoffeeScript or other languages to JavaScript, use the `prepublish` +CoffeeScript or other languages to JavaScript, use the `prepare` script to do this, and make the required package a devDependency. For example: @@ -529,12 +529,12 @@ For example: "coffee-script": "~1.6.3" }, "scripts": { - "prepublish": "coffee -o lib/ -c src/waza.coffee" + "prepare": "coffee -o lib/ -c src/waza.coffee" }, "main": "lib/waza.js" } -The `prepublish` script will be run before publishing, so that users +The `prepare` script will be run before publishing, so that users can consume the functionality without requiring them to compile it themselves. In dev mode (ie, locally running `npm install`), it'll run this script as well, so that you can test it easily. |