Skip to content

Commit

Permalink
Add dependabot and GH actions workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
tpyo committed Nov 22, 2023
1 parent 1f9823f commit f2b4b86
Show file tree
Hide file tree
Showing 3 changed files with 78 additions and 0 deletions.
12 changes: 12 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# To get started with Dependabot version updates, you'll need to specify which
# package ecosystems to update and where the package manifests are located.
# Please see the documentation for all configuration options:
# https://docs.github.com/github/administering-a-repository/configuration-options-for-dependency-updates

version: 2
updates:
- package-ecosystem: "cargo"
directory: "/"
open-pull-requests-limit: 1
schedule:
interval: "daily"
34 changes: 34 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: Build

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

on:
push:
branches: [main, master, production]

env:
CARGO_TERM_COLOR: always

jobs:
lint-and-tests:
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v3

- uses: actions/cache@v2
with:
path: |
~/.cargo/registry
~/.cargo/git
target
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}

- name: Build
run: cargo build --verbose

- name: Run tests
run: cargo test --verbose

32 changes: 32 additions & 0 deletions .github/workflows/pr.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: PR

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

on: pull_request

env:
CARGO_TERM_COLOR: always

jobs:
lint-and-tests:
runs-on: ubuntu-latest
steps:
- name: Check out repository
uses: actions/checkout@v3

- uses: actions/cache@v2
with:
path: |
~/.cargo/registry
~/.cargo/git
target
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}

- name: Build
run: cargo build --verbose

- name: Run tests
run: cargo test --verbose

0 comments on commit f2b4b86

Please sign in to comment.