forked from bergercookie/asm-lsp
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add pre-commit configuration. Link to it via gh action
- Loading branch information
1 parent
51c1225
commit 3c51f99
Showing
8 changed files
with
60 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,7 +3,8 @@ name: Lint Code / Run Tests | |
on: | ||
workflow_dispatch: | ||
push: | ||
branches: ["master"] | ||
branches: | ||
- "*" | ||
paths: | ||
- "src/**" | ||
- "Cargo.*" | ||
|
@@ -38,12 +39,9 @@ jobs: | |
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
|
||
- run: rustup toolchain install ${{ matrix.rust }} --profile minimal | ||
- uses: Swatinem/rust-cache@v2 | ||
|
||
- name: Run rustfmt checks | ||
run: cargo fmt --check | ||
|
||
- name: Run clippy lints | ||
run: cargo clippy -- -D warnings | ||
- uses: actions/setup-python@v3 | ||
- uses: pre-commit/[email protected] | ||
name: Run pre-commit hooks |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -15,6 +15,10 @@ jobs: | |
- uses: actions/checkout@v3 | ||
name: Checkout | ||
|
||
- uses: actions/setup-python@v3 | ||
- uses: pre-commit/[email protected] | ||
name: Run pre-commit hooks | ||
|
||
- uses: actions-rs/toolchain@v1 | ||
with: | ||
toolchain: stable | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"ignorePatterns": ["https://crates.io/crates/asm-lsp"] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
repos: | ||
- repo: https://github.com/pre-commit/pre-commit-hooks | ||
rev: "v4.4.0" | ||
hooks: | ||
- id: check-added-large-files | ||
- id: check-merge-conflict | ||
- id: check-toml | ||
- id: detect-private-key | ||
- id: end-of-file-fixer | ||
- id: mixed-line-ending | ||
- id: trailing-whitespace | ||
- repo: https://github.com/tcort/markdown-link-check | ||
rev: "v3.10.3" | ||
hooks: | ||
# https://github.com/tcort/markdown-link-check#config-file-format | ||
- id: markdown-link-check | ||
args: ["--progress", "--config", ".markdown-link-check.json"] | ||
- repo: https://github.com/markdownlint/markdownlint | ||
rev: "v0.12.0" | ||
hooks: | ||
- id: markdownlint | ||
exclude: ^.github/ | ||
entry: mdl -r ~MD033,~MD013,~MD034,~MD029,~MD007 | ||
- repo: https://github.com/python-jsonschema/check-jsonschema | ||
rev: "0.27.0" | ||
hooks: | ||
- id: check-github-workflows | ||
args: ["--verbose", "--builtin-schema", "vendor.github-workflows"] | ||
files: ^\.github/workflows/ | ||
types: [yaml] | ||
- repo: meta | ||
hooks: | ||
- id: check-hooks-apply | ||
- id: check-useless-excludes | ||
|
||
- repo: https://github.com/doublify/pre-commit-rust | ||
rev: v1.0 | ||
hooks: | ||
- id: fmt | ||
- id: cargo-check | ||
args: ["--locked"] | ||
- id: clippy |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
[package] | ||
name = "asm-lsp" | ||
version = "0.4.0" | ||
version = "0.4.1" | ||
authors = ["Nikos Koukis <[email protected]>"] | ||
edition = "2018" | ||
|
||
|