-
Notifications
You must be signed in to change notification settings - Fork 20
69 lines (54 loc) · 1.72 KB
/
Copy pathrust.yml
File metadata and controls
69 lines (54 loc) · 1.72 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
name: Rust
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
env:
CARGO_TERM_COLOR: always
permissions:
contents: read
pages: write
id-token: write
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install LLVM
run: |
sudo wget https://apt.llvm.org/llvm.sh
sudo chmod +x llvm.sh
sudo ./llvm.sh 20 all
sudo update-alternatives --install /usr/bin/llvm-link llvm-link "$(command -v llvm-link-20)" 200
sudo update-alternatives --set llvm-link "$(command -v llvm-link-20)"
sudo update-alternatives --install /usr/bin/lli lli "$(command -v lli-20)" 200
sudo update-alternatives --set lli "$(command -v lli-20)"
sudo update-alternatives --install /usr/bin/clang clang "$(command -v clang-20)" 200
sudo update-alternatives --set clang "$(command -v clang-20)"
sudo apt-get install qemu-user gcc-aarch64-linux-gnu
- name: Run basic tests
run: |
cargo test --verbose
doc:
runs-on: ubuntu-latest
if: github.event_name == 'push'
needs: build
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
- uses: actions/checkout@v4
- name: Setup Rust toolchain
uses: dtolnay/rust-toolchain@stable
- name: Generate rustdoc
run: |
cargo doc --no-deps --document-private-items
echo '<meta http-equiv="refresh" content="0; url=teac/index.html">' > target/doc/index.html
- name: Upload Pages artifact
uses: actions/upload-pages-artifact@v3
with:
path: target/doc
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4