mirror of
https://gitea.com/gitea/docs.git
synced 2026-07-21 10:17:42 +00:00
Add support for npm unpublish (#20688)
This commit is contained in:
@@ -67,6 +67,26 @@ npm publish
|
|||||||
|
|
||||||
You cannot publish a package if a package of the same name and version already exists. You must delete the existing package first.
|
You cannot publish a package if a package of the same name and version already exists. You must delete the existing package first.
|
||||||
|
|
||||||
|
## Unpublish a package
|
||||||
|
|
||||||
|
Delete a package by running the following command:
|
||||||
|
|
||||||
|
```shell
|
||||||
|
npm unpublish {package_name}[@{package_version}]
|
||||||
|
```
|
||||||
|
|
||||||
|
| Parameter | Description |
|
||||||
|
| ----------------- | ----------- |
|
||||||
|
| `package_name` | The package name. |
|
||||||
|
| `package_version` | The package version. |
|
||||||
|
|
||||||
|
For example:
|
||||||
|
|
||||||
|
```shell
|
||||||
|
npm unpublish @test/test_package
|
||||||
|
npm unpublish @test/test_package@1.0.0
|
||||||
|
```
|
||||||
|
|
||||||
## Install a package
|
## Install a package
|
||||||
|
|
||||||
To install a package from the package registry, execute the following command:
|
To install a package from the package registry, execute the following command:
|
||||||
@@ -113,6 +133,7 @@ The tag name must not be a valid version. All tag names which are parsable as a
|
|||||||
npm install
|
npm install
|
||||||
npm ci
|
npm ci
|
||||||
npm publish
|
npm publish
|
||||||
|
npm unpublish
|
||||||
npm dist-tag
|
npm dist-tag
|
||||||
npm view
|
npm view
|
||||||
```
|
```
|
||||||
|
|||||||
Reference in New Issue
Block a user