Skip to content

Commit 4e2947a

Browse files
authored
fix(ci): Use orb for GitHub CLI (#5078)
1 parent 9308d06 commit 4e2947a

File tree

1 file changed

+6
-16
lines changed

1 file changed

+6
-16
lines changed

.circleci/config.yml

Lines changed: 6 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ orbs:
1919
node: circleci/[email protected]
2020
heroku: circleci/[email protected]
2121
browser-tools: circleci/[email protected]
22+
gh: circleci/[email protected]
2223

2324
executors:
2425
slds-executor:
@@ -194,17 +195,6 @@ commands:
194195
fi
195196
fi
196197
197-
install-gh-cli:
198-
description: 'Install Github CLI'
199-
steps:
200-
- run:
201-
name: Install Github CLI
202-
command: |
203-
sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-key C99B11DEB97541F0
204-
sudo apt-add-repository https://cli.github.com/packages
205-
sudo apt update
206-
sudo apt install gh
207-
208198
launch-static-storybook:
209199
description: 'Launch local static Storybook server'
210200
steps:
@@ -231,7 +221,7 @@ jobs:
231221
steps:
232222
- checkout
233223
- run: mkdir -p workspace
234-
- install-gh-cli
224+
- gh/install
235225
- get-pr-number
236226

237227
- run:
@@ -350,7 +340,7 @@ jobs:
350340
- attach_workspace:
351341
at: workspace
352342

353-
- install-gh-cli
343+
- gh/install
354344

355345
- run:
356346
name: 'Github: attach artifact to release'
@@ -452,7 +442,7 @@ jobs:
452442
heroku buildpacks -a ${PUBLISH_STORYBOOK_TO} | grep "https://github.com/salesforce-ux/heroku-buildpack-nginx.git#dse" || heroku buildpacks:set https://github.com/salesforce-ux/heroku-buildpack-nginx.git#dse -a ${PUBLISH_STORYBOOK_TO}
453443
heroku builds:create --source-tar workspace/storybook.tar.gz -a ${PUBLISH_STORYBOOK_TO}
454444
455-
- install-gh-cli
445+
- gh/install
456446
- run:
457447
name: Set Github deployments to "success"
458448
command: |
@@ -520,7 +510,7 @@ jobs:
520510
heroku buildpacks -a ${HEROKU_APP_NAME} | grep "https://github.com/salesforce-ux/heroku-buildpack-nginx.git#dse" || heroku buildpacks:set https://github.com/salesforce-ux/heroku-buildpack-nginx.git#dse -a ${HEROKU_APP_NAME}
521511
heroku builds:create --source-tar site-next.tar.gz -a ${HEROKU_APP_NAME}
522512
523-
- install-gh-cli
513+
- gh/install
524514
- run:
525515
name: Set Github deployments to "success"
526516
command: |
@@ -537,7 +527,7 @@ jobs:
537527
steps:
538528
- checkout
539529
- run: mkdir -p workspace
540-
- install-gh-cli
530+
- gh/install
541531
- get-pr-number
542532

543533
- persist_to_workspace:

0 commit comments

Comments
 (0)