-
Notifications
You must be signed in to change notification settings - Fork 2
165 lines (153 loc) · 3.82 KB
/
main.yml
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
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
name: CI
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
# Allows you to run this workflow manually
workflow_dispatch:
jobs:
AoC-2015:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.13'
- name: Install dependencies
run: |
cd 2015
python -m pip install --upgrade pip
pip install .
- name: Run AoC 2015
run: |
cd 2015
pylint .
pytest
AoC-2016:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: '3.3'
- name: Run AoC 2016
run: |
cd 2016
bundler install
rubocop
rake
AoC-2017:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '22.x'
- name: Run AoC 2017
run: |
cd 2017
npm ci
npx eslint src/**/*
npx prettier src/**/* --check
npx jest
AoC-2018:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up .Net Core
uses: actions/setup-dotnet@v4
with:
dotnet-version: '9.0.x'
- name: Compile and run AoC 2018
run: |
cd 2018
dotnet tool restore
DOTNET_ROLL_FORWARD=latestMajor dotnet csharpier --check src
dotnet build -c Release
dotnet test bin/Release/net9.0/aoc2018.dll
AoC-2019:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up JDK 17
uses: actions/setup-java@v4
with:
java-version: '17'
distribution: 'temurin'
- name: Compile and run AoC 2019
run: |
cd 2019
./gradlew check
AoC-2020:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up packages
run: |
sudo apt update
sudo apt install -y libdw-dev libunwind-dev
- name: Compile and run AoC 2020
run: |
cd 2020
./build/make.sh
time ./cmake-build-release/adventofcode
AoC-2021:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up JDK 17
uses: actions/setup-java@v4
with:
java-version: '17'
distribution: 'temurin'
- name: Compile and run AoC 2021
run: |
cd 2021
./gradlew check
AoC-2022:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up JDK 21
uses: actions/setup-java@v4
with:
java-version: '21'
distribution: 'temurin'
- name: Compile and run AoC 2022
run: |
cd 2022
./gradlew check
AoC-2023:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up packages
run: |
sudo apt update
sudo apt install -y rustc cargo
- name: Compile and run AoC 2023
run: |
cd 2023
cargo fmt --check
cargo build --release
time cargo test --release
AoC-2024:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up .Net Core
uses: actions/setup-dotnet@v4
with:
dotnet-version: 9.0.x
- name: Compile and run AoC 2024
run: |
cd 2024
dotnet tool restore
dotnet fantomas --check src/*
DOTNET_ROLL_FORWARD=latestMajor dotnet fsharplint lint src/*
dotnet build -c Release
dotnet test bin/Release/net9.0/aoc2024.dll