Skip to content

Commit

Permalink
GitHub Action: enable binary cache
Browse files Browse the repository at this point in the history
  • Loading branch information
gapry authored Jun 9, 2024
1 parent ae8255d commit db1a9d9
Showing 1 changed file with 16 additions and 2 deletions.
18 changes: 16 additions & 2 deletions .github/workflows/develop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,22 @@ name: CI

on: [push, pull_request, workflow_dispatch]

env:
VCPKG_BINARY_SOURCES: "clear;x-gha,readwrite"

jobs:
ci-ubuntu:
name: Build on Linux (Ubuntu)
runs-on: ubuntu-latest
steps:
- name: Export GitHub Actions cache environment variables
uses: actions/github-script@v7
with:
script: |
core.exportVariable('ACTIONS_CACHE_URL', process.env.ACTIONS_CACHE_URL || '');
core.exportVariable('ACTIONS_RUNTIME_TOKEN', process.env.ACTIONS_RUNTIME_TOKEN || '');
- uses: actions/checkout@v4
- uses: lukka/get-cmake@latest
- name: install SDL2
run: sudo apt update -y && sudo apt install -y libsdl2-dev
- name: install dependencies
run: ./vcpkg.sh
- name: build
Expand All @@ -22,6 +29,12 @@ jobs:
name: Build on MacOS
runs-on: macOS-latest
steps:
- name: Export GitHub Actions cache environment variables
uses: actions/github-script@v7
with:
script: |
core.exportVariable('ACTIONS_CACHE_URL', process.env.ACTIONS_CACHE_URL || '');
core.exportVariable('ACTIONS_RUNTIME_TOKEN', process.env.ACTIONS_RUNTIME_TOKEN || '');
- uses: actions/checkout@v4
- uses: lukka/get-cmake@latest
- name: install dependencies
Expand All @@ -30,6 +43,7 @@ jobs:
run: make build
- name: build
run: make test

fmt:
name: Formatting Check
runs-on: ubuntu-latest
Expand Down

0 comments on commit db1a9d9

Please sign in to comment.