Skip to content

Commit

Permalink
update template
Browse files Browse the repository at this point in the history
  • Loading branch information
majcn committed Nov 29, 2023
1 parent 767395c commit 6d46832
Show file tree
Hide file tree
Showing 76 changed files with 1,410 additions and 768 deletions.
7 changes: 0 additions & 7 deletions .cargo/config

This file was deleted.

11 changes: 11 additions & 0 deletions .cargo/config.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
[alias]
scaffold = "run --quiet --release -- scaffold"
download = "run --quiet --release -- download"
read = "run --quiet --release -- read"

solve = "run --quiet --release -- solve"
all = "run --quiet --release -- all"
time = "run --quiet --release -- all --release --time"

[env]
AOC_YEAR = "2022"
31 changes: 13 additions & 18 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,31 +6,26 @@ env:
CARGO_TERM_COLOR: always

jobs:
check:
runs-on: ubuntu-latest
name: Check
steps:
- uses: actions/checkout@v3
- name: cargo check
run: cargo check
test:
runs-on: ubuntu-latest
name: Test
name: CI
steps:
- uses: actions/checkout@v3
- name: Set up cargo cache
uses: actions/cache@v3
continue-on-error: false
with:
path: |
~/.cargo/bin/
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
target/
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
restore-keys: ${{ runner.os }}-cargo-
- name: cargo test
run: cargo test
clippy:
runs-on: ubuntu-latest
name: Lint (clippy)
steps:
- uses: actions/checkout@v3
- name: cargo clippy
run: cargo clippy -- -D warnings
fmt:
runs-on: ubuntu-latest
name: Format
steps:
- uses: actions/checkout@v3
- name: cargo fmt
run: cargo fmt --check
16 changes: 5 additions & 11 deletions .github/workflows/readme-stars.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,22 +9,16 @@ on:
jobs:
update-readme:
runs-on: ubuntu-latest
if: ${{ vars.AOC_ENABLED == 'true' }}
permissions:
contents: write
steps:
- uses: actions/checkout@v3
if: ${{ env.AOC_ENABLED }}
env:
AOC_ENABLED: ${{ secrets.AOC_ENABLED }}
- uses: actions/checkout@v4
- uses: k2bd/advent-readme-stars@v1
if: ${{ env.AOC_ENABLED }}
env:
AOC_ENABLED: ${{ secrets.AOC_ENABLED }}
with:
userId: ${{ secrets.AOC_USER_ID }}
sessionCookie: ${{ secrets.AOC_SESSION }}
year: ${{ secrets.AOC_YEAR }}
- uses: stefanzweifel/git-auto-commit-action@v4
if: ${{ env.AOC_ENABLED }}
env:
AOC_ENABLED: ${{ secrets.AOC_ENABLED }}
- uses: stefanzweifel/git-auto-commit-action@v5
with:
commit_message: "update readme progess"
8 changes: 6 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -16,5 +16,9 @@ target/

# Advent of Code
# @see https://old.reddit.com/r/adventofcode/comments/k99rod/sharing_input_data_were_we_requested_not_to/gf2ukkf/?context=3
/src/inputs
!/src/inputs/.keep

data

!data/inputs/.keep
!data/examples/.keep
!data/puzzles/.keep
22 changes: 11 additions & 11 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 8 additions & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,12 +1,18 @@
[package]
name = "advent_of_code"
version = "0.8.0"
version = "0.9.2"
authors = ["Felix Spöttel <1682504+fspoettel@users.noreply.github.com>"]
edition = "2021"
default-run = "advent_of_code"
publish = false
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html

[lib]
doctest = false

[features]
test_lib = []

[dependencies]
pico-args = "0.5.0"
regex = "1.9.5"
regex = "1.10.2"
Loading

0 comments on commit 6d46832

Please sign in to comment.