summaryrefslogtreecommitdiff
path: root/deps/npm/doc/api/submodule.md
diff options
context:
space:
mode:
Diffstat (limited to 'deps/npm/doc/api/submodule.md')
-rw-r--r--deps/npm/doc/api/submodule.md28
1 files changed, 28 insertions, 0 deletions
diff --git a/deps/npm/doc/api/submodule.md b/deps/npm/doc/api/submodule.md
new file mode 100644
index 0000000000..2d8bafaa31
--- /dev/null
+++ b/deps/npm/doc/api/submodule.md
@@ -0,0 +1,28 @@
+npm-submodule(3) -- Add a package as a git submodule
+====================================================
+
+## SYNOPSIS
+
+ npm.commands.submodule(packages, callback)
+
+## DESCRIPTION
+
+For each package specified, npm will check if it has a git repository url
+in its package.json description then add it as a git submodule at
+`node_modules/<pkg name>`.
+
+This is a convenience only. From then on, it's up to you to manage
+updates by using the appropriate git commands. npm will stubbornly
+refuse to update, modify, or remove anything with a `.git` subfolder
+in it.
+
+This command also does not install missing dependencies, if the package
+does not include them in its git repository. If `npm ls` reports that
+things are missing, you can either install, link, or submodule them yourself,
+or you can do `npm explore <pkgname> -- npm install` to install the
+dependencies into the submodule folder.
+
+## SEE ALSO
+
+* npm help json
+* git help submodule