-
-
Notifications
You must be signed in to change notification settings - Fork 115
50 lines (48 loc) · 1.43 KB
/
Copy pathci.yml
File metadata and controls
50 lines (48 loc) · 1.43 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
name: Continuous Integration
on:
pull_request:
branches: ["**"]
push:
branches: ["main"]
jobs:
build:
name: Build and Test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- uses: actions/setup-java@v5
with:
distribution: temurin
java-version: 25
- uses: coursier/cache-action@v6
- uses: VirtusLab/scala-cli-setup@main
with:
scala-cli-version: 1.12.2
- run: scala-cli fmt --check .
- run: scala-cli --server=false build.scala
- name: Save PR number
if: github.event_name == 'pull_request'
run: echo "${{ github.event.pull_request.number }}" > pr_number.txt
- name: Upload site artifact
if: github.event_name == 'pull_request'
uses: actions/upload-artifact@v4
with:
name: site
path: target
if-no-files-found: error
retention-days: 30
- name: Upload PR number artifact
if: github.event_name == 'pull_request'
uses: actions/upload-artifact@v4
with:
name: pr-number
path: pr_number.txt
if-no-files-found: error
retention-days: 30
- name: Publish to GitHub Pages
if: github.event_name == 'push'
uses: peaceiris/actions-gh-pages@v4.0.0
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: target
cname: typelevel.org