mirror of
https://github.com/bitwarden/directory-connector
synced 2026-02-19 02:43:40 +00:00
Compare commits
4 Commits
main
...
ac/pm-2047
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
c9d75dbe48 | ||
|
|
73311ccd4c | ||
|
|
6f0ab084d8 | ||
|
|
83ef9888e6 |
34
.github/actions/setup-node-env/action.yml
vendored
Normal file
34
.github/actions/setup-node-env/action.yml
vendored
Normal file
@@ -0,0 +1,34 @@
|
||||
name: "Setup Node Environment"
|
||||
description: "Sets up Node.js with npm cache and installs node-gyp"
|
||||
inputs:
|
||||
node-version:
|
||||
description: "Node.js version to use"
|
||||
required: true
|
||||
platform:
|
||||
description: "Platform name (Linux, macOS, Windows) - used for shell selection"
|
||||
required: false
|
||||
default: "Linux"
|
||||
|
||||
runs:
|
||||
using: "composite"
|
||||
steps:
|
||||
- name: Set up Node
|
||||
uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238 # v6.2.0
|
||||
with:
|
||||
cache: "npm"
|
||||
cache-dependency-path: "**/package-lock.json"
|
||||
node-version: ${{ inputs.node-version }}
|
||||
|
||||
- name: Update NPM and install node-gyp (Unix)
|
||||
if: inputs.platform != 'Windows'
|
||||
shell: bash
|
||||
run: |
|
||||
npm install -g node-gyp
|
||||
node-gyp install "$(node -v)"
|
||||
|
||||
- name: Update NPM and install node-gyp (Windows)
|
||||
if: inputs.platform == 'Windows'
|
||||
shell: pwsh
|
||||
run: |
|
||||
npm install -g node-gyp
|
||||
node-gyp install $(node -v)
|
||||
76
.github/workflows/build.yml
vendored
76
.github/workflows/build.yml
vendored
@@ -55,17 +55,11 @@ jobs:
|
||||
with:
|
||||
persist-credentials: false
|
||||
|
||||
- name: Set up Node
|
||||
uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238 # v6.2.0
|
||||
- name: Setup Node Environment
|
||||
uses: ./.github/actions/setup-node-env
|
||||
with:
|
||||
cache: 'npm'
|
||||
cache-dependency-path: '**/package-lock.json'
|
||||
node-version: ${{ env._NODE_VERSION }}
|
||||
|
||||
- name: Update NPM
|
||||
run: |
|
||||
npm install -g node-gyp
|
||||
node-gyp install "$(node -v)"
|
||||
platform: Linux
|
||||
|
||||
- name: Keytar
|
||||
run: |
|
||||
@@ -133,17 +127,11 @@ jobs:
|
||||
with:
|
||||
persist-credentials: false
|
||||
|
||||
- name: Set up Node
|
||||
uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238 # v6.2.0
|
||||
- name: Setup Node Environment
|
||||
uses: ./.github/actions/setup-node-env
|
||||
with:
|
||||
cache: 'npm'
|
||||
cache-dependency-path: '**/package-lock.json'
|
||||
node-version: ${{ env._NODE_VERSION }}
|
||||
|
||||
- name: Update NPM
|
||||
run: |
|
||||
npm install -g node-gyp
|
||||
node-gyp install "$(node -v)"
|
||||
platform: macOS
|
||||
|
||||
- name: Keytar
|
||||
run: |
|
||||
@@ -208,17 +196,11 @@ jobs:
|
||||
run: |
|
||||
choco install checksum --no-progress
|
||||
|
||||
- name: Set up Node
|
||||
uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238 # v6.2.0
|
||||
- name: Setup Node Environment
|
||||
uses: ./.github/actions/setup-node-env
|
||||
with:
|
||||
cache: 'npm'
|
||||
cache-dependency-path: '**/package-lock.json'
|
||||
node-version: ${{ env._NODE_VERSION }}
|
||||
|
||||
- name: Update NPM
|
||||
run: |
|
||||
npm install -g node-gyp
|
||||
node-gyp install $(node -v)
|
||||
platform: Windows
|
||||
|
||||
- name: Keytar
|
||||
shell: pwsh
|
||||
@@ -243,8 +225,8 @@ jobs:
|
||||
run: npm run dist:cli:win
|
||||
|
||||
- name: Zip
|
||||
shell: cmd
|
||||
run: 7z a .\dist-cli\bwdc-windows-%_PACKAGE_VERSION%.zip .\dist-cli\windows\bwdc.exe .\keytar\windows\keytar.node
|
||||
shell: pwsh
|
||||
run: 7z a .\dist-cli\bwdc-windows-$env:_PACKAGE_VERSION.zip .\dist-cli\windows\bwdc.exe .\keytar\windows\keytar.node
|
||||
|
||||
- name: Version Test
|
||||
shell: pwsh
|
||||
@@ -283,17 +265,11 @@ jobs:
|
||||
with:
|
||||
persist-credentials: false
|
||||
|
||||
- name: Set up Node
|
||||
uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238 # v6.2.0
|
||||
- name: Setup Node Environment
|
||||
uses: ./.github/actions/setup-node-env
|
||||
with:
|
||||
cache: 'npm'
|
||||
cache-dependency-path: '**/package-lock.json'
|
||||
node-version: ${{ env._NODE_VERSION }}
|
||||
|
||||
- name: Update NPM
|
||||
run: |
|
||||
npm install -g node-gyp
|
||||
node-gyp install $(node -v)
|
||||
platform: Windows
|
||||
|
||||
- name: Print environment
|
||||
run: |
|
||||
@@ -383,17 +359,11 @@ jobs:
|
||||
with:
|
||||
persist-credentials: false
|
||||
|
||||
- name: Set up Node
|
||||
uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238 # v6.2.0
|
||||
- name: Setup Node Environment
|
||||
uses: ./.github/actions/setup-node-env
|
||||
with:
|
||||
cache: 'npm'
|
||||
cache-dependency-path: '**/package-lock.json'
|
||||
node-version: ${{ env._NODE_VERSION }}
|
||||
|
||||
- name: Update NPM
|
||||
run: |
|
||||
npm install -g node-gyp
|
||||
node-gyp install "$(node -v)"
|
||||
platform: Linux
|
||||
|
||||
- name: Set up environment
|
||||
run: |
|
||||
@@ -443,17 +413,11 @@ jobs:
|
||||
with:
|
||||
persist-credentials: false
|
||||
|
||||
- name: Set up Node
|
||||
uses: actions/setup-node@6044e13b5dc448c55e2357c09f80417699197238 # v6.2.0
|
||||
- name: Setup Node Environment
|
||||
uses: ./.github/actions/setup-node-env
|
||||
with:
|
||||
cache: 'npm'
|
||||
cache-dependency-path: '**/package-lock.json'
|
||||
node-version: ${{ env._NODE_VERSION }}
|
||||
|
||||
- name: Update NPM
|
||||
run: |
|
||||
npm install -g node-gyp
|
||||
node-gyp install "$(node -v)"
|
||||
platform: macOS
|
||||
|
||||
- name: Print environment
|
||||
run: |
|
||||
|
||||
Reference in New Issue
Block a user