Skip to content

Commit 760a12b

Browse files
committed
use actions/cache
1 parent 6ad2f19 commit 760a12b

File tree

1 file changed

+9
-7
lines changed

1 file changed

+9
-7
lines changed

.github/workflows/mac.yml

+9-7
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,8 @@ jobs:
3636
INSTALL_DIR_JS: ${{ github.workspace }}/openvino_install/js
3737
INSTALL_TEST_DIR: ${{ github.workspace }}/tests_install
3838
BUILD_DIR: ${{ github.workspace }}/build
39+
CCACHE_DIR: ${{ github.workspace }}/ccache
40+
CCACHE_MAXSIZE: '2G'
3941
GRADLE_VER: '7.1.1'
4042
steps:
4143
- name: Clone OpenVINO
@@ -64,7 +66,7 @@ jobs:
6466
#
6567

6668
- name: Install build dependencies
67-
run: brew install coreutils ninja scons automake gradle
69+
run: brew install coreutils ninja scons automake gradle ccache
6870

6971
- name: Setup Python ${{ env.PYTHON_VERSION }}
7072
uses: actions/setup-python@v5
@@ -79,16 +81,15 @@ jobs:
7981
#
8082

8183
- name: Setup ccache
82-
uses: hendrikmuhs/ccache-action@v1.2
84+
uses: actions/cache@v4
8385
with:
84-
max-size: "2000M"
8586
# Should save cache only if run in the master branch of the base repo
8687
# github.ref_name is 'ref/PR_#' in case of the PR, and 'branch_name' when executed on push
87-
save: ${{ github.ref_name == 'master' && 'true' || 'false' }}
88-
verbose: 2
89-
key: ${{ runner.os }}-${{ runner.arch }}-main
88+
save-always: ${{ github.ref_name == 'master' && 'true' || 'false' }}
89+
path: ${{ env.CCACHE_DIR }}
90+
key: ${{ runner.os }}-${{ runner.arch }}-ccache-${{ github.sha }}
9091
restore-keys: |
91-
${{ runner.os }}-${{ runner.arch }}-main
92+
${{ runner.os }}-${{ runner.arch }}-ccache
9293
9394
- name: CMake configure
9495
run: |
@@ -107,6 +108,7 @@ jobs:
107108
-DENABLE_OV_TF_LITE_FRONTEND=OFF \
108109
-DENABLE_OV_PYTORCH_FRONTEND=OFF \
109110
-DENABLE_CPPLINT=OFF \
111+
-DENABLE_INTEL_NPU=OFF \
110112
-S ${{ env.OPENVINO_REPO }} \
111113
-B ${{ env.BUILD_DIR }}
112114

0 commit comments

Comments
 (0)