# semantic-release-npm-multiple-scoped

> A semantic release plugin to publish an NPM package to multiple registries.

Latest version **1.0.6** (published 2021-08-10) · MIT license · 0 weekly downloads

## Install

```sh
npm install semantic-release-npm-multiple-scoped
pnpm add semantic-release-npm-multiple-scoped
yarn add semantic-release-npm-multiple-scoped
bun add semantic-release-npm-multiple-scoped
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.6 |
| Published | 2021-08-10 |
| First published | 2021-08-10 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 3 |
| Unpacked size | 6.7 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Amanda Mitchell |
| Maintainers | voronianski |
| Keywords | npm, publish, registry, semantic-release, version |

## Links

- npm: https://www.npmjs.com/package/semantic-release-npm-multiple-scoped
- Repository: https://github.com/voronianki/semantic-release-npm-multiple
- Homepage: https://github.com/voronianki/semantic-release-npm-multiple#readme
- Issues: https://github.com/voronianki/semantic-release-npm-multiple/issues
- npm.io page: https://npm.io/package/semantic-release-npm-multiple-scoped

## Dependencies (3)

- [async](https://npm.io/package/async.md) ^3.2.1
- [require-reload](https://npm.io/package/require-reload.md) ^0.2.2
- [@semantic-release/npm](https://npm.io/package/@semantic-release/npm.md) ^7.0.6

## Recent versions

- 1.0.6 (latest) — 2021-08-10
- 1.0.5 — 2021-08-10
- 1.0.4 — 2021-08-10
- 1.0.3 — 2021-08-10
- 1.0.2 — 2021-08-10
- 1.0.1 — 2021-08-10
- 1.0.0 — 2021-08-10

## README

# semantic-release-npm-multiple-scoped

This is a thin wrapper around the [@semantic-release/npm](https://github.com/semantic-release/npm) plugin for [Semantic Release](https://semantic-release.gitbook.io/semantic-release/) that allows it to be called multiple times, which can be useful if you need to publish to multiple NPM registries simultaneously.

It's a fork of https://github.com/amanda-mitchell/semantic-release-npm-multiple package but with support of scoped registries.

## Installation

```
yarn add --dev semantic-release-npm-multiple-scoped
```

## Usage

The plugin can be configured in the [**semantic-release** configuration file](https://github.com/semantic-release/semantic-release/blob/master/docs/usage/configuration.md#configuration):

```json
{
  "plugins": [
    "@semantic-release/commit-analyzer",
    "@semantic-release/release-notes-generator",
    [
      "semantic-release-npm-multiple-scoped",
      {
        "registries": {
          "registryName1": {
            "npmPublish": true
          },
          "registryName2": {
            "npmPublish": true
          }
        }
      }
    ]
  ]
}
```

## Configuration

Each of the keys in `registries` refers to a specific registry that should be used and may be any value that is meaningful to you.
The object associated with that key is a set of options that should be passed to the `@semantic-release/npm` plugin when calling it.

`@amanda-mitchell/semantic-release-npm-multiple` also looks at a number of environment variables for its configuration:

- `NPM_TOKEN`
- `NPM_USERNAME`
- `NPM_PASSWORD`
- `NPM_EMAIL`
- `NPM_CONFIG_REGISTRY`
- `REGISTRY_SCOPE`

For any of these variables, if you define a `{UPPER_CASE_REGISTRY_NAME}_{VARIABLE}` environment variable, it will be used instead.

For example, if you wanted to publish a package to both a GitHub private registry and the public NPM registry, you would first create a configuration file like this:

```json
{
  "plugins": [
    "@semantic-release/commit-analyzer",
    "@semantic-release/release-notes-generator",
    [
      "semantic-release-npm-multiple-scoped",
      {
        "registries": {
          "github": {},
          "public": {}
        }
      }
    ]
  ]
}
```

And then, when running `semantic-release`, set these environment variables:

- `GITHUB_NPM_CONFIG_REGISTRY=https://npm.pkg.github.com/`
- `GITHUB_NPM_TOKEN=XXXXX`
- `PUBLIC_NPM_CONFIG_REGISTRY=https://registry.npmjs.org`
- `PUBLIC_NPM_TOKEN=XXXXX`

---
_Source: https://npm.io/package/semantic-release-npm-multiple-scoped · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
