Skip to content

Commit

Permalink
Merge pull request #3 from danieleades/ci
Browse files Browse the repository at this point in the history
add CI workflows
  • Loading branch information
VirxEC authored Oct 20, 2024
2 parents 7d3aacf + c435473 commit e545e74
Show file tree
Hide file tree
Showing 5 changed files with 248 additions and 5 deletions.
45 changes: 45 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@

version: 2
updates:
# bump major and minor updates as soon as available
- package-ecosystem: cargo
target-branch: main # see https://github.com/dependabot/dependabot-core/issues/1778#issuecomment-1988140219
directory: /
schedule:
interval: daily
commit-message:
prefix: chore
include: scope
ignore:
- dependency-name: "*"
update-types:
- "version-update:semver-patch"

# bundle patch updates together on a monthly basis
- package-ecosystem: cargo
directory: /
schedule:
interval: monthly
commit-message:
prefix: chore
include: scope
groups:
patch-updates:
update-types:
- patch
ignore:
- dependency-name: "*"
update-types:
- "version-update:semver-minor"
- "version-update:semver-major"

# bump actions as soon as available
- package-ecosystem: github-actions
directory: /
schedule:
interval: daily
commit-message:
prefix: chore
include: scope
ignore:
- dependency-name: dtolnay/rust-toolchain
55 changes: 55 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
on:
push:
branches: [master]
pull_request:

name: Continuous integration

jobs:
test:
name: test
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
features: ["--features glam", ""]
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@nightly
- run: cargo test ${{ matrix.features }}

fmt:
name: format
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@nightly
with:
components: rustfmt
- run: cargo fmt --all --check

clippy:
name: lint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@nightly
with:
components: clippy
- uses: actions-rs-plus/clippy-check@v2
with:
args: --all --all-features --all-targets

msrv:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- name: Get MSRV from Cargo.toml
run: |
MSRV=$(grep 'rust-version' Cargo.toml | sed 's/.*= *"\(.*\)".*/\1/')
echo "MSRV=$MSRV" >> $GITHUB_ENV
- uses: dtolnay/rust-toolchain@master
with:
toolchain: ${{ env.MSRV }}
- uses: taiki-e/install-action@cargo-no-dev-deps
- run: cargo no-dev-deps check --all --all-features
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
/target
/.vscode
Cargo.lock
*.svg
*.data*
147 changes: 147 additions & 0 deletions Cargo.lock

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

5 changes: 1 addition & 4 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ repository = "https://github.com/VirxEC/dubins_paths"
license = "MIT"
keywords = ["rocket-league", "rlbot", "physics", "simulation", "dubin"]
categories = ["science", "simulation", "algorithms"]
rust-version = "1.62.1"
rust-version = "1.68.2"

# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html

Expand All @@ -20,9 +20,6 @@ rand = "0.8.5"
[dependencies]
glam = { version = "0.29.0", optional = true }

[features]
glam = ["dep:glam"]

[profile.release]
codegen-units = 1
lto = true
Expand Down

0 comments on commit e545e74

Please sign in to comment.