summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAchilleas Pipinellis <axil@gitlab.com>2019-07-09 15:42:14 +0000
committerAchilleas Pipinellis <axil@gitlab.com>2019-07-09 15:42:14 +0000
commit5d439257a641c08f0e5e3fe09991a53d211e8c13 (patch)
tree852c3b13d60aa5d79aa5eee52364f142f6066bf0
parent9bcf55747e445702dd07997ac20d52fe3dfa640f (diff)
parent00369eba01cb796b2affaf4592de3c439ab1addc (diff)
downloadgitlab-ce-5d439257a641c08f0e5e3fe09991a53d211e8c13.tar.gz
Merge branch '63583-update-npm-documentation-with-new-naming-conventions' into 'master'
Resolve "Update NPM documentation with new naming conventions." Closes #63583 See merge request gitlab-org/gitlab-ce!29935
-rw-r--r--doc/user/project/packages/npm_registry.md15
1 files changed, 8 insertions, 7 deletions
diff --git a/doc/user/project/packages/npm_registry.md b/doc/user/project/packages/npm_registry.md
index b2cfe10836f..481b1ce0337 100644
--- a/doc/user/project/packages/npm_registry.md
+++ b/doc/user/project/packages/npm_registry.md
@@ -11,11 +11,6 @@ project can have its own space to store NPM packages.
NOTE: **Note:**
Only [scoped](https://docs.npmjs.com/misc/scope) packages are supported.
-
-NOTE: **Note:**
-As `@group/subgroup/project` is not a valid NPM package name, publishing a package
-within a subgroup is not supported yet.
-
## Enabling the NPM Registry
NOTE: **Note:**
@@ -36,12 +31,15 @@ get familiar with the package naming convention.
## Package naming convention
-**Only packages that have the same path as the project** are supported. For
- example:
+**Packages must be scoped in the root namespace of the project**. The package
+name may be anything but it is preferred that the project name be used unless
+it is not possible due to a naming collision. For example:
| Project | Package | Supported |
| ---------------------- | ----------------------- | --------- |
| `foo/bar` | `@foo/bar` | Yes |
+| `foo/bar/baz` | `@foo/baz` | Yes |
+| `foo/bar/buz` | `@foo/anything` | Yes |
| `gitlab-org/gitlab-ce` | `@gitlab-org/gitlab-ce` | Yes |
| `gitlab-org/gitlab-ce` | `@foo/bar` | No |
@@ -113,6 +111,9 @@ npm publish
You can then navigate to your project's **Packages** page and see the uploaded
packages or even delete them.
+If you attempt to publish a package with a name that already exists within
+a given scope, you will receive a `403 Forbidden!` error.
+
## Uploading a package with the same version twice
If you upload a package with a same name and version twice, GitLab will show