Skip to content

Commit 302fa41

Browse files
committed
Add copilot setup.
1 parent 1ea5b46 commit 302fa41

1 file changed

Lines changed: 65 additions & 0 deletions

File tree

Lines changed: 65 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,65 @@
1+
name: "Copilot Setup Steps"
2+
3+
on:
4+
workflow_dispatch:
5+
push:
6+
paths:
7+
- .github/workflows/copilot-setup-steps.yml
8+
pull_request:
9+
paths:
10+
- .github/workflows/copilot-setup-steps.yml
11+
12+
jobs:
13+
copilot-setup-steps:
14+
runs-on: ubuntu-latest
15+
16+
steps:
17+
- uses: actions/checkout@v3
18+
with:
19+
submodules: recursive
20+
21+
- name: Install opam
22+
run: |
23+
sudo apt update
24+
sudo apt install -y opam
25+
opam init --bare
26+
27+
- name: Install Z3
28+
run: |
29+
echo "PATH=/usr/local/bin/:$PATH" >> $GITHUB_ENV
30+
sudo ./opt/fstar/.scripts/get_fstar_z3.sh /usr/local/bin/
31+
32+
- name: Compute cache key
33+
id: cachekey
34+
run: |
35+
echo "cachekey=$(./opt/ci-deps-hash)" >> "$GITHUB_OUTPUT"
36+
37+
- name: Get cache
38+
id: getcache
39+
uses: actions/cache/restore@v4
40+
with:
41+
path: opt
42+
key: ${{ steps.cachekey.outputs.cachekey }}
43+
44+
- name: Restore changes to files in opt
45+
run: |
46+
git reset --hard
47+
48+
- name: Build dependencies
49+
run: |
50+
make -j$(nproc) build-pulse
51+
52+
- name: Save cache
53+
if: ${{ steps.getcache.outputs.cache-hit != 'true' }}
54+
uses: actions/cache/save@v4
55+
with:
56+
path: opt
57+
key: ${{ steps.cachekey.outputs.cachekey }}
58+
59+
- name: Install clang
60+
run: |
61+
wget https://apt.llvm.org/llvm.sh
62+
chmod +x llvm.sh
63+
sudo ./llvm.sh 20
64+
sudo apt update
65+
sudo apt install -y clang-20 libclang-cpp20-dev g++ clang-tools-20 libclang-20-dev

0 commit comments

Comments
 (0)