Skip to content

Commit

Permalink
Initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
jssblck authored Jun 3, 2024
0 parents commit 874edaf
Show file tree
Hide file tree
Showing 16 changed files with 933 additions and 0 deletions.
18 changes: 18 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# 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: "/"
schedule:
interval: "daily"
open-pull-requests-limit: 1

- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "daily"
open-pull-requests-limit: 1
44 changes: 44 additions & 0 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
# Overview

_Provide an overview of this change. Describe the intent of this change, and how it implements that intent._

_Example: This PR accomplishes X by doing Y._

## Acceptance criteria

_If this PR is successful, what impact does it have on the user experience?_

_Example: When users do X, Y should now happen._

## Testing plan

_How did you validate that this PR works? What literal steps did you take when manually checking that your code works?_

_Example:_

1. _Set up test case X._
2. _Run command Y. Make sure Z happens._

_This section should list concrete steps that a reviewer can sanity check and repeat on their own machine (and provide any needed test cases)._

## Metrics

_How are we monitoring this change?_

## Risks

_Highlight any areas that you're unsure of, want feedback on, or want reviewers to pay particular attention to._

_Example: I'm not sure I did X correctly, can reviewers please double-check that for me?_

## References

_Add links to any referenced GitHub issues, Zendesk tickets, Jira tickets, Slack threads, etc._

_Example:_

- _[ANE-123](https://fossa.atlassian.net/browse/ANE-123): Implement X._

## Checklist

- [ ] I added tests for this PR's change (or explained in the PR description why tests don't make sense).
18 changes: 18 additions & 0 deletions .github/workflows/check-dependencies.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
name: dependencies
on: push

jobs:
check-fossa:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- run: "curl -H 'Cache-Control: no-cache' https://raw.githubusercontent.com/fossas/fossa-cli/master/install-latest.sh | bash"

- run: fossa analyze --only-target cargo .
env:
FOSSA_API_KEY: ${{ secrets.FOSSA_API_KEY }}

- run: fossa test
env:
FOSSA_API_KEY: ${{ secrets.FOSSA_API_KEY }}
32 changes: 32 additions & 0 deletions .github/workflows/check-dynamic.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: dynamic
on: pull_request

jobs:
check-build:
strategy:
matrix:
settings:
- host: windows-latest
setup: echo "no setup"
build: cargo build
- host: ubuntu-latest
setup: echo "no setup"
build: cargo build
- host: macos-latest
setup: rustup target add aarch64-apple-darwin
build: cargo build --target aarch64-apple-darwin && cargo build --target x86_64-apple-darwin

runs-on: ${{ matrix.settings.host }}
name: test / ${{ matrix.settings.host }}
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
- uses: taiki-e/install-action@nextest
- uses: Swatinem/[email protected]
with:
key: ${{ matrix.settings.host }}
- run: ${{ matrix.settings.setup }}
- run: ${{ matrix.settings.build }}
- run: cargo check --release --all --bins --examples --tests
- run: cargo nextest run --all-targets
- run: cargo test --doc
13 changes: 13 additions & 0 deletions .github/workflows/check-static.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
name: static

on: pull_request

jobs:
check-static:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable

- run: cargo fmt --all -- --check
- run: cargo clippy --all-features --all --tests -- -D clippy::all
19 changes: 19 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# Generated by Cargo
# will have compiled files and executables
debug/
target/

# Remove Cargo.lock from gitignore if creating an executable, leave it for libraries
# More information here https://doc.rust-lang.org/cargo/guide/cargo-toml-vs-cargo-lock.html
Cargo.lock

# These are backup files generated by rustfmt
**/*.rs.bk

# MSVC Windows builds of rustc generate these, which store debugging information
*.pdb


# Added by cargo

/target
17 changes: 17 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
{
"cSpell.words": [
"aarch",
"clippy",
"CODEOWNER",
"CODEOWNERS",
"doctest",
"doctests",
"dtolnay",
"libc",
"msvc",
"nextest",
"rustup",
"Swatinem",
"taiki"
]
}
8 changes: 8 additions & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
[package]
name = "template-rust"
version = "0.1.0"
edition = "2021"

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

[dependencies]
Loading

0 comments on commit 874edaf

Please sign in to comment.