ci(lint): do not fail linter on `push` events (#5331)
Previous behavior: The following error was causing an exit 1 in GitHub Actions when a pushing to the `main` branch ``` Error: Similar commit hashes detected: previous sha is equivalent to the current sha ``` Expeceted behavior: Allow the linter to run succesfully even if the previous SHA has no files changed Solution: Add `fetch-depth: 2` to retrieve the preceding commit
This commit is contained in:
parent
9f6a1fdef0
commit
a4189857fd
|
@ -41,6 +41,7 @@ jobs:
|
||||||
id: changed-files-rust
|
id: changed-files-rust
|
||||||
uses: tj-actions/changed-files@v29.0.7
|
uses: tj-actions/changed-files@v29.0.7
|
||||||
with:
|
with:
|
||||||
|
fetch-depth: 2
|
||||||
files: |
|
files: |
|
||||||
**/*.rs
|
**/*.rs
|
||||||
**/Cargo.toml
|
**/Cargo.toml
|
||||||
|
@ -53,6 +54,7 @@ jobs:
|
||||||
id: changed-files-workflows
|
id: changed-files-workflows
|
||||||
uses: tj-actions/changed-files@v29.0.7
|
uses: tj-actions/changed-files@v29.0.7
|
||||||
with:
|
with:
|
||||||
|
fetch-depth: 2
|
||||||
files: |
|
files: |
|
||||||
.github/workflows/*.yml
|
.github/workflows/*.yml
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue