Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/npm/cli.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorGrey Baker <greysteil@gmail.com>2019-01-30 02:52:59 +0300
committerAudrey Eschright <audrey@lifeofaudrey.com>2019-02-14 22:19:49 +0300
commitaa32239aed86fc5c65f02823d7bb5cb52f647bfb (patch)
treeb1318ca7d532023535aea7abaab7910b613cfb76 /doc
parente37c0cd071b0ce78c3712907c78c2fc1981bed8a (diff)
doc: update package.json docs to include repository.directory details (#140)
PR-URL: https://github.com/npm/cli/pull/140 Credit: @greysteil Reviewed-By: @aeschright
Diffstat (limited to 'doc')
-rw-r--r--doc/files/package.json.md9
1 files changed, 9 insertions, 0 deletions
diff --git a/doc/files/package.json.md b/doc/files/package.json.md
index dd6492af0..95e77d34c 100644
--- a/doc/files/package.json.md
+++ b/doc/files/package.json.md
@@ -393,6 +393,15 @@ shortcut syntax you use for `npm install`:
"repository": "gitlab:user/repo"
+If the `package.json` for your package is not in the root directory (for example
+if it is part of a monorepo), you can specify the directory in which it lives:
+
+ "repository": {
+ "type" : "git",
+ "url" : "https://github.com/facebook/react.git",
+ "directory": "packages/react-dom"
+ }
+
## scripts
The "scripts" property is a dictionary containing script commands that are run