Install `yq` by APT on ubuntu of gh-actions.

`brew intall` on Ubuntu is too slow (about 1 min)
This commit is contained in:
Cotes Chung 2020-09-17 13:54:12 +08:00
parent 6f7ca13507
commit 2cf5a58adf
2 changed files with 18 additions and 10 deletions

View File

@ -29,8 +29,18 @@ jobs:
with:
ruby-version: '2.6.x'
- name: install tooling
- name: Install tools (for Ubuntu)
if: matrix.os == 'ubuntu-latest'
run: |
sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys CC86BB64
sudo add-apt-repository ppa:rmescandon/yq
sudo apt update
sudo apt install yq -y
- name: Install tools (for macOS)
if: matrix.os == 'macos-latest'
run: |
brew install coreutils
brew install yq
- name: Checkout
@ -47,11 +57,6 @@ jobs:
restore-keys: |
${{ runner.os }}-gems-
- name: Install GNU-Coreutils(for macOS)
if: runner.os == 'macOS'
run: |
brew install coreutils
- name: Bundle config
run: |
bundle config path vendor/bundle

View File

@ -17,15 +17,18 @@ jobs:
with:
ruby-version: '2.6.x'
- name: Install tools
run: |
sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys CC86BB64
sudo add-apt-repository ppa:rmescandon/yq
sudo apt update
sudo apt install yq -y
- name: Checkout
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Install yq
run: |
brew install yq
- name: Bundle Caching
id: bundle-cache
uses: actions/cache@v1