Skip to content
refresh-cw

GitHub Action

npm mirror sync action

v1.1.0 Latest version

npm mirror sync action

refresh-cw

npm mirror sync action

🔄 将 npm 包新版本同步到 npm 镜像,支持 npmmirror.com

Installation

Copy and paste the following snippet into your .yml file.

              

- name: npm mirror sync action

uses: FrontEndDev-org/[email protected]

Learn more about this action in FrontEndDev-org/npm-mirror-sync-action

Choose a version

npm-mirror-sync-action

code-review dependency-review Codacy Badge release marketplace license

🔄 将 npm 包新版本同步到 npm 镜像,支持 npmmirror.com

工作流样例

jobs:
  release:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v3
      - run: npm ci
      - run: npm run build
      - uses: FrontEndDev-org/publish-node-package-action@v1
        with:
          target: npm
          token: ${{ secrets.NPM_TOKEN }}
      - name: 自动将上一步发布的的 npm 包版本同步到 npmmirror.com
        uses: FrontEndDev-org/npm-mirror-sync-action@v1

配置项

参数名 可选性 描述
name 可选 待同步的 npm 包名称,默认从当前目录 package.json 里读取
target 可选 同步镜像的目标,默认 npmmirror(即 npmmirror.com),暂无其他可选值
timeout 可选 同步超时时间,默认 30 秒