Skip to content

Commit 6364842

Browse files
authored
chore(NODE-5348): consolidate setup action (#3724)
1 parent 8e02256 commit 6364842

File tree

6 files changed

+23
-43
lines changed

6 files changed

+23
-43
lines changed

.github/actions/setup.yml

Lines changed: 0 additions & 11 deletions
This file was deleted.

.github/actions/setup/action.yml

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
name: Setup
2+
description: 'Installs node, driver dependencies, and builds source'
3+
4+
runs:
5+
using: composite
6+
steps:
7+
- uses: actions/setup-node@v3
8+
with:
9+
node-version: 'lts/*'
10+
cache: 'npm'
11+
registry-url: 'https://registry.npmjs.org'
12+
- run: npm install -g npm@latest
13+
shell: bash
14+
- run: npm clean-install
15+
shell: bash

.github/workflows/build_docs.yml

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -19,14 +19,8 @@ jobs:
1919

2020
steps:
2121
- uses: actions/checkout@v3
22-
# TODO: replace with setup
23-
- uses: actions/setup-node@v3
24-
with:
25-
node-version: 'lts/*'
26-
cache: 'npm'
27-
registry-url: 'https://registry.npmjs.org'
28-
- run: npm install -g npm@latest
29-
- run: npm clean-install
22+
- name: actions/setup
23+
uses: ./.github/actions/setup
3024
- run: sudo apt-get install hugo
3125
- name: Build Docs
3226
run: npm run build:docs -- --yes

.github/workflows/dependencies.yml

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -14,12 +14,6 @@ jobs:
1414
runs-on: ubuntu-latest
1515
steps:
1616
- uses: actions/checkout@v3
17-
# TODO: replace with setup
18-
- uses: actions/setup-node@v3
19-
with:
20-
node-version: 'lts/*'
21-
cache: 'npm'
22-
registry-url: 'https://registry.npmjs.org'
23-
- run: npm install -g npm@latest
24-
- run: npm clean-install
17+
- name: actions/setup
18+
uses: ./.github/actions/setup
2519
- run: npm run check:dependencies

.github/workflows/release-alpha.yml

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -25,14 +25,8 @@ jobs:
2525
exit 1
2626
fi
2727
- uses: actions/checkout@v3
28-
# TODO: replace with setup
29-
- uses: actions/setup-node@v3
30-
with:
31-
node-version: 'lts/*'
32-
cache: 'npm'
33-
registry-url: 'https://registry.npmjs.org'
34-
- run: npm install -g npm@latest
35-
- run: npm clean-install
28+
- name: actions/setup
29+
uses: ./.github/actions/setup
3630
- run: npm version "${{ inputs.alphaVersion }}" --git-tag-version=false
3731
- run: npm publish --provenance --tag=alpha
3832
env:

.github/workflows/release-nightly.yml

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -20,14 +20,8 @@ jobs:
2020
id-token: write
2121
steps:
2222
- uses: actions/checkout@v3
23-
# TODO: replace with setup
24-
- uses: actions/setup-node@v3
25-
with:
26-
node-version: 'lts/*'
27-
cache: 'npm'
28-
registry-url: 'https://registry.npmjs.org'
29-
- run: npm install -g npm@latest
30-
- run: npm clean-install
23+
- name: actions/setup
24+
uses: ./.github/actions/setup
3125
- id: build_nightly
3226
run: npm run build:nightly
3327
- if: ${{ steps.build_nightly.outputs.publish == 'yes' }}

0 commit comments

Comments
 (0)