Skip to content

Commit f6623fe

Browse files
committed
workflow: create workflow for generating caches seperately
Google rate limits the pulling so having multiple workflows pulling at the same time from google seems stupid. Just use github, it was built for this.
1 parent 60b28fc commit f6623fe

1 file changed

Lines changed: 69 additions & 0 deletions

File tree

.github/workflows/cache.yml

Lines changed: 69 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,69 @@
1+
name: Generate Caches
2+
3+
on:
4+
workflow_dispatch:
5+
6+
jobs:
7+
build:
8+
# This requires about 25GB to properly download. Please make sure the runner can provide that.
9+
runs-on: self-hosted
10+
steps:
11+
- name: Checkout
12+
uses: actions/checkout@v4
13+
# This bit always takes forever to finish cloning so lets just cache it
14+
- name: Cache third_party/llvm
15+
uses: actions/cache@v4
16+
with:
17+
path: third_party/llvm
18+
key: third_party-llvm
19+
- name: Cache third_party/VK-GL-CTS
20+
uses: actions/cache@v4
21+
with:
22+
path: third_party/VK-GL-CTS
23+
key: third_party-VK-GL-CTS
24+
- name: Cache third_party/SwiftShader
25+
uses: actions/cache@v4
26+
with:
27+
path: third_party/SwiftShader
28+
key: third_party-SwiftShader
29+
- name: Cache third_party/dawn
30+
uses: actions/cache@v4
31+
with:
32+
path: third_party/dawn
33+
key: third_party-dawn
34+
- name: Cache depot_tools
35+
uses: actions/cache@v4
36+
with:
37+
path: depot_tools
38+
key: depot-tools
39+
# This should only be rarely ran so its here so the cache priority still is somewhat biggest to smallest
40+
- name: Install depot_tools
41+
run: |
42+
if [ ! -d "depot_tools" ] ; then
43+
git clone https://chromium.googlesource.com/chromium/tools/depot_tools.git
44+
fi
45+
echo "$PWD/depot_tools" >> $GITHUB_PATH
46+
- name: Cache tools
47+
uses: actions/cache@v4
48+
with:
49+
path: tools
50+
key: tools
51+
- name: Cache build
52+
uses: actions/cache@v4
53+
with:
54+
path: build
55+
key: build
56+
57+
- name: Fetch ANGLE and dependencies
58+
run: |
59+
gclient config --spec 'solutions = [
60+
{
61+
"name": ".",
62+
"url": "https://chromium.googlesource.com/angle/angle.git",
63+
"deps_file": "DEPS",
64+
"managed": False,
65+
"custom_vars": {},
66+
},
67+
]
68+
target_os = ["ios", "android"]'
69+
gclient sync -Rf

0 commit comments

Comments
 (0)