File tree 5 files changed +82
-0
lines changed
5 files changed +82
-0
lines changed Original file line number Diff line number Diff line change
1
+ name : pre-commit
2
+
3
+ on :
4
+ pull_request :
5
+ push :
6
+ branches : [master]
7
+
8
+ jobs :
9
+ pre-commit :
10
+ runs-on : ubuntu-latest
11
+ steps :
12
+ - uses : actions/checkout@v3
13
+ - uses : actions/setup-python@v3
14
+ - uses : pre-commit/action@v3.0.0
Original file line number Diff line number Diff line change
1
+ name : ruby
2
+
3
+ on :
4
+ pull_request :
5
+ push :
6
+ branches : [master]
7
+
8
+ defaults :
9
+ run :
10
+ working-directory : ./2024/ruby
11
+
12
+ jobs :
13
+ tests :
14
+ runs-on : ubuntu-latest
15
+ steps :
16
+ - uses : actions/checkout@v3
17
+ - name : Determine ruby version
18
+ id : determine-ruby-version
19
+ run : |
20
+ VERSION=$(cat .ruby-version)
21
+ echo "VERSION=${VERSION}" >> "$GITHUB_OUTPUT"
22
+ - name : Set up Ruby
23
+ uses : ruby/setup-ruby@v1
24
+ with :
25
+ ruby-version : ${{ steps.determine-ruby-version.outputs.VERSION }}
26
+ bundler-cache : true
27
+ - name : Install gems
28
+ run : |
29
+ gem update bundler
30
+ bundle
31
+ - name : Run tests
32
+ run : bundle exec rspec
Original file line number Diff line number Diff line change
1
+ ruby 3.3.6
Original file line number Diff line number Diff line change
1
+ # Advent of Code
2
+
3
+ Solutions for [ Advent of Code 2024] ( https://adventofcode.com/2024 ) done in Ruby
4
+
5
+ ## Setup
6
+
7
+ bundle install --binstubs
8
+
9
+ ### Runnning tests
10
+
11
+ ./bin/rspec spec
12
+
13
+ ### Code style
14
+
15
+ Keep style up to date with rubocop:
16
+
17
+ ./bin/rubocop --auto-gen-config
18
+ # remove auto-correctable files from rubocop_todo.yml
19
+ ./bin/rubocop -a
Original file line number Diff line number Diff line change 1
1
# Advent of Code
2
2
3
+ [ ![ ruby] ( https://github.com/invalidusrname/adventofcode/actions/workflows/ruby.yaml/badge.svg )] ( https://github.com/invalidusrname/adventofcode/actions/workflows/ruby.yaml )
4
+
5
+
3
6
4
7
My solutions for [ Advent of Code] ( https://adventofcode.com ) problems.
5
8
6
9
See nested folders (year/language) for further information on setting up and running the code.
10
+
11
+
12
+ ## Setup
13
+
14
+ ```
15
+ brew install pre-commit
16
+ pre-commit install
17
+ mise install
18
+ ```
19
+
20
+ ### Running exercises
21
+
22
+ See instructions in each language subdirectory
You can’t perform that action at this time.
0 commit comments