mirror of
https://github.com/ClementTsang/bottom.git
synced 2026-08-24 20:36:42 +00:00
ci: Use commit hash for some actions to pin them
This commit is contained in:
+17
-17
@@ -25,7 +25,7 @@ jobs:
|
||||
- windows-2019
|
||||
steps:
|
||||
- id: skip_check
|
||||
uses: fkirc/skip-duplicate-actions@master
|
||||
uses: fkirc/skip-duplicate-actions@38c3738dcac87b41e2b7038775457756c793566e # https://github.com/fkirc/skip-duplicate-actions/commit/38c3738dcac87b41e2b7038775457756c793566e
|
||||
with:
|
||||
concurrent_skipping: "same_content_newer"
|
||||
skip_after_successful_duplicate: "true"
|
||||
@@ -35,7 +35,7 @@ jobs:
|
||||
- uses: actions/checkout@v2
|
||||
if: ${{ steps.skip_check.outputs.should_skip != 'true' }}
|
||||
|
||||
- uses: actions-rs/toolchain@v1
|
||||
- uses: actions-rs/toolchain@b2417cde72dcf67f306c0ae8e0828a81bf0b189f # 1.0.6
|
||||
if: ${{ steps.skip_check.outputs.should_skip != 'true' }}
|
||||
with:
|
||||
profile: minimal
|
||||
@@ -43,7 +43,7 @@ jobs:
|
||||
override: true
|
||||
components: rustfmt
|
||||
|
||||
- uses: Swatinem/rust-cache@v1
|
||||
- uses: Swatinem/rust-cache@842ef286fff290e445b90b4002cc9807c3669641 # 1.3.0
|
||||
if: ${{ steps.skip_check.outputs.should_skip != 'true' }}
|
||||
|
||||
- run: cargo fmt --all -- --check
|
||||
@@ -60,7 +60,7 @@ jobs:
|
||||
- windows-2019
|
||||
steps:
|
||||
- id: skip_check
|
||||
uses: fkirc/skip-duplicate-actions@master
|
||||
uses: fkirc/skip-duplicate-actions@38c3738dcac87b41e2b7038775457756c793566e # https://github.com/fkirc/skip-duplicate-actions/commit/38c3738dcac87b41e2b7038775457756c793566e
|
||||
with:
|
||||
concurrent_skipping: "same_content_newer"
|
||||
skip_after_successful_duplicate: "true"
|
||||
@@ -70,7 +70,7 @@ jobs:
|
||||
- uses: actions/checkout@v2
|
||||
if: ${{ steps.skip_check.outputs.should_skip != 'true' }}
|
||||
|
||||
- uses: actions-rs/toolchain@v1
|
||||
- uses: actions-rs/toolchain@b2417cde72dcf67f306c0ae8e0828a81bf0b189f # 1.0.6
|
||||
if: ${{ steps.skip_check.outputs.should_skip != 'true' }}
|
||||
with:
|
||||
profile: minimal
|
||||
@@ -78,7 +78,7 @@ jobs:
|
||||
override: true
|
||||
components: clippy
|
||||
|
||||
- uses: Swatinem/rust-cache@v1
|
||||
- uses: Swatinem/rust-cache@842ef286fff290e445b90b4002cc9807c3669641 # 1.3.0
|
||||
if: ${{ steps.skip_check.outputs.should_skip != 'true' }}
|
||||
|
||||
- run: cargo clippy --all-targets --workspace -- -D warnings
|
||||
@@ -193,7 +193,7 @@ jobs:
|
||||
|
||||
steps:
|
||||
- id: skip_check
|
||||
uses: fkirc/skip-duplicate-actions@master
|
||||
uses: fkirc/skip-duplicate-actions@38c3738dcac87b41e2b7038775457756c793566e # https://github.com/fkirc/skip-duplicate-actions/commit/38c3738dcac87b41e2b7038775457756c793566e
|
||||
with:
|
||||
concurrent_skipping: "same_content_newer"
|
||||
skip_after_successful_duplicate: "true"
|
||||
@@ -205,21 +205,21 @@ jobs:
|
||||
|
||||
- name: Install toolchain
|
||||
if: ${{ steps.skip_check.outputs.should_skip != 'true' }}
|
||||
uses: actions-rs/toolchain@v1
|
||||
uses: actions-rs/toolchain@b2417cde72dcf67f306c0ae8e0828a81bf0b189f # 1.0.6
|
||||
with:
|
||||
profile: minimal
|
||||
toolchain: ${{ matrix.triple.rust }}
|
||||
override: true
|
||||
target: ${{ matrix.triple.target }}
|
||||
|
||||
- uses: Swatinem/rust-cache@v1
|
||||
- uses: Swatinem/rust-cache@842ef286fff290e445b90b4002cc9807c3669641 # 1.3.0
|
||||
if: ${{ steps.skip_check.outputs.should_skip != 'true' }}
|
||||
with:
|
||||
key: ${{ matrix.triple.target }}
|
||||
|
||||
- name: Check
|
||||
if: ${{ steps.skip_check.outputs.should_skip != 'true' }}
|
||||
uses: actions-rs/cargo@v1
|
||||
uses: actions-rs/cargo@ae10961054e4aa8b4aa7dffede299aaf087aa33b # 1.0.1
|
||||
with:
|
||||
command: check
|
||||
args: --all-targets --verbose --target=${{ matrix.triple.target }} --features "battery"
|
||||
@@ -255,7 +255,7 @@ jobs:
|
||||
|
||||
steps:
|
||||
- id: skip_check
|
||||
uses: fkirc/skip-duplicate-actions@master
|
||||
uses: fkirc/skip-duplicate-actions@38c3738dcac87b41e2b7038775457756c793566e # https://github.com/fkirc/skip-duplicate-actions/commit/38c3738dcac87b41e2b7038775457756c793566e
|
||||
with:
|
||||
concurrent_skipping: "same_content_newer"
|
||||
skip_after_successful_duplicate: "true"
|
||||
@@ -267,21 +267,21 @@ jobs:
|
||||
|
||||
- name: Install toolchain
|
||||
if: ${{ steps.skip_check.outputs.should_skip != 'true' }}
|
||||
uses: actions-rs/toolchain@v1
|
||||
uses: actions-rs/toolchain@b2417cde72dcf67f306c0ae8e0828a81bf0b189f # 1.0.6
|
||||
with:
|
||||
profile: minimal
|
||||
toolchain: ${{ matrix.triple.rust }}
|
||||
override: true
|
||||
target: ${{ matrix.triple.target }}
|
||||
|
||||
- uses: Swatinem/rust-cache@v1
|
||||
- uses: Swatinem/rust-cache@842ef286fff290e445b90b4002cc9807c3669641 # 1.3.0
|
||||
if: ${{ steps.skip_check.outputs.should_skip != 'true' }}
|
||||
with:
|
||||
key: ${{ matrix.triple.target }}
|
||||
|
||||
- name: Check without battery feature on the main 3
|
||||
if: ${{ steps.skip_check.outputs.should_skip != 'true' }}
|
||||
uses: actions-rs/cargo@v1
|
||||
uses: actions-rs/cargo@ae10961054e4aa8b4aa7dffede299aaf087aa33b # 1.0.1
|
||||
with:
|
||||
command: check
|
||||
args: --all-targets --verbose --target=${{ matrix.triple.target }} --no-default-features
|
||||
@@ -317,7 +317,7 @@ jobs:
|
||||
|
||||
steps:
|
||||
- id: skip_check
|
||||
uses: fkirc/skip-duplicate-actions@master
|
||||
uses: fkirc/skip-duplicate-actions@38c3738dcac87b41e2b7038775457756c793566e # https://github.com/fkirc/skip-duplicate-actions/commit/38c3738dcac87b41e2b7038775457756c793566e
|
||||
with:
|
||||
concurrent_skipping: "same_content_newer"
|
||||
skip_after_successful_duplicate: "true"
|
||||
@@ -329,14 +329,14 @@ jobs:
|
||||
|
||||
- name: Install toolchain
|
||||
if: ${{ steps.skip_check.outputs.should_skip != 'true' }}
|
||||
uses: actions-rs/toolchain@v1
|
||||
uses: actions-rs/toolchain@b2417cde72dcf67f306c0ae8e0828a81bf0b189f # 1.0.6
|
||||
with:
|
||||
profile: minimal
|
||||
toolchain: ${{ matrix.triple.rust }}
|
||||
override: true
|
||||
target: ${{ matrix.triple.target }}
|
||||
|
||||
- uses: Swatinem/rust-cache@v1
|
||||
- uses: Swatinem/rust-cache@842ef286fff290e445b90b4002cc9807c3669641 # 1.3.0
|
||||
if: ${{ steps.skip_check.outputs.should_skip != 'true' }}
|
||||
with:
|
||||
key: ${{ matrix.triple.target }}
|
||||
|
||||
@@ -16,7 +16,7 @@ jobs:
|
||||
should_skip: ${{ steps.skip_check.outputs.should_skip }}
|
||||
steps:
|
||||
- id: skip_check
|
||||
uses: fkirc/skip-duplicate-actions@master
|
||||
uses: fkirc/skip-duplicate-actions@38c3738dcac87b41e2b7038775457756c793566e # https://github.com/fkirc/skip-duplicate-actions/commit/38c3738dcac87b41e2b7038775457756c793566e
|
||||
with:
|
||||
concurrent_skipping: "same_content_newer"
|
||||
skip_after_successful_duplicate: "true"
|
||||
@@ -34,7 +34,7 @@ jobs:
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
|
||||
- uses: Swatinem/rust-cache@v1
|
||||
- uses: Swatinem/rust-cache@842ef286fff290e445b90b4002cc9807c3669641 # 1.3.0
|
||||
with:
|
||||
key: ${{ matrix.triple.target }}
|
||||
|
||||
@@ -43,6 +43,6 @@ jobs:
|
||||
cargo tarpaulin --verbose --all-features --workspace --run-types AllTargets --timeout 120 --out Xml
|
||||
|
||||
- name: Upload to codecov.io
|
||||
uses: codecov/codecov-action@v2
|
||||
uses: codecov/codecov-action@f32b3a3741e1053eb607407145bc9619351dc93b # 2.1.0
|
||||
with:
|
||||
fail_ci_if_error: true
|
||||
|
||||
@@ -140,19 +140,19 @@ jobs:
|
||||
fetch-depth: 1
|
||||
|
||||
- name: Install toolchain
|
||||
uses: actions-rs/toolchain@v1
|
||||
uses: actions-rs/toolchain@b2417cde72dcf67f306c0ae8e0828a81bf0b189f # 1.0.6
|
||||
with:
|
||||
profile: minimal
|
||||
toolchain: stable
|
||||
override: true
|
||||
target: ${{ matrix.triple.target }}
|
||||
|
||||
- uses: Swatinem/rust-cache@v1
|
||||
- uses: Swatinem/rust-cache@842ef286fff290e445b90b4002cc9807c3669641 # 1.3.0
|
||||
with:
|
||||
key: ${{ matrix.triple.target }}
|
||||
|
||||
- name: Build
|
||||
uses: actions-rs/cargo@v1
|
||||
uses: actions-rs/cargo@ae10961054e4aa8b4aa7dffede299aaf087aa33b # 1.0.1
|
||||
with:
|
||||
command: build
|
||||
args: --release --verbose --target=${{ matrix.triple.target }} --features "battery"
|
||||
@@ -243,19 +243,19 @@ jobs:
|
||||
run: Install-WindowsFeature Net-Framework-Core
|
||||
|
||||
- name: Install wixtoolset (Windows x86-64 MSVC)
|
||||
uses: crazy-max/ghaction-chocolatey@v1.4.0
|
||||
uses: crazy-max/ghaction-chocolatey@87d06bbbd2cfb1835f1820042d356aef4875fb5f # 1.6.0
|
||||
with:
|
||||
args: install -y wixtoolset
|
||||
|
||||
- name: Install toolchain
|
||||
uses: actions-rs/toolchain@v1
|
||||
uses: actions-rs/toolchain@b2417cde72dcf67f306c0ae8e0828a81bf0b189f # 1.0.6
|
||||
with:
|
||||
profile: minimal
|
||||
toolchain: stable
|
||||
override: true
|
||||
target: x86_64-pc-windows-msvc
|
||||
|
||||
- uses: Swatinem/rust-cache@v1
|
||||
- uses: Swatinem/rust-cache@842ef286fff290e445b90b4002cc9807c3669641 # 1.3.0
|
||||
with:
|
||||
key: x86_64-pc-windows-msvc-msi
|
||||
|
||||
@@ -315,14 +315,14 @@ jobs:
|
||||
echo "Release version: ${{ env.RELEASE_VERSION }}"
|
||||
|
||||
- name: Install toolchain
|
||||
uses: actions-rs/toolchain@v1
|
||||
uses: actions-rs/toolchain@b2417cde72dcf67f306c0ae8e0828a81bf0b189f # 1.0.6
|
||||
with:
|
||||
profile: minimal
|
||||
toolchain: stable
|
||||
override: true
|
||||
target: x86_64-unknown-linux-gnu
|
||||
|
||||
- uses: Swatinem/rust-cache@v1
|
||||
- uses: Swatinem/rust-cache@842ef286fff290e445b90b4002cc9807c3669641 # 1.3.0
|
||||
with:
|
||||
key: x86_64-unknown-linux-gnu-deb
|
||||
|
||||
@@ -429,7 +429,7 @@ jobs:
|
||||
ls ./release
|
||||
|
||||
- name: Upload all saved release files
|
||||
uses: softprops/action-gh-release@v1
|
||||
uses: softprops/action-gh-release@17cd0d34deddf848fc0e7d9be5202c148c270a0a # 0.1.14
|
||||
with:
|
||||
token: ${{ secrets.GITHUB_TOKEN }}
|
||||
prerelease: false
|
||||
|
||||
@@ -136,19 +136,19 @@ jobs:
|
||||
fetch-depth: 1
|
||||
|
||||
- name: Install toolchain
|
||||
uses: actions-rs/toolchain@v1
|
||||
uses: actions-rs/toolchain@b2417cde72dcf67f306c0ae8e0828a81bf0b189f # 1.0.6
|
||||
with:
|
||||
profile: minimal
|
||||
toolchain: stable
|
||||
override: true
|
||||
target: ${{ matrix.triple.target }}
|
||||
|
||||
- uses: Swatinem/rust-cache@v1
|
||||
- uses: Swatinem/rust-cache@842ef286fff290e445b90b4002cc9807c3669641 # 1.3.0
|
||||
with:
|
||||
key: ${{ matrix.triple.target }}
|
||||
|
||||
- name: Build
|
||||
uses: actions-rs/cargo@v1
|
||||
uses: actions-rs/cargo@ae10961054e4aa8b4aa7dffede299aaf087aa33b # 1.0.1
|
||||
with:
|
||||
command: build
|
||||
args: --release --verbose --target=${{ matrix.triple.target }} --features "battery"
|
||||
@@ -237,19 +237,19 @@ jobs:
|
||||
run: Install-WindowsFeature Net-Framework-Core
|
||||
|
||||
- name: Install wixtoolset
|
||||
uses: crazy-max/ghaction-chocolatey@v1.4.0
|
||||
uses: crazy-max/ghaction-chocolatey@87d06bbbd2cfb1835f1820042d356aef4875fb5f # 1.6.0
|
||||
with:
|
||||
args: install -y wixtoolset
|
||||
|
||||
- name: Install toolchain
|
||||
uses: actions-rs/toolchain@v1
|
||||
uses: actions-rs/toolchain@b2417cde72dcf67f306c0ae8e0828a81bf0b189f # 1.0.6
|
||||
with:
|
||||
profile: minimal
|
||||
toolchain: stable
|
||||
override: true
|
||||
target: x86_64-pc-windows-msvc
|
||||
|
||||
- uses: Swatinem/rust-cache@v1
|
||||
- uses: Swatinem/rust-cache@842ef286fff290e445b90b4002cc9807c3669641 # 1.3.0
|
||||
with:
|
||||
key: x86_64-pc-windows-msvc-msi
|
||||
|
||||
@@ -302,14 +302,14 @@ jobs:
|
||||
echo "Release version: ${{ env.RELEASE_VERSION }}"
|
||||
|
||||
- name: Install toolchain
|
||||
uses: actions-rs/toolchain@v1
|
||||
uses: actions-rs/toolchain@b2417cde72dcf67f306c0ae8e0828a81bf0b189f # 1.0.6
|
||||
with:
|
||||
profile: minimal
|
||||
toolchain: stable
|
||||
override: true
|
||||
target: x86_64-unknown-linux-gnu
|
||||
|
||||
- uses: Swatinem/rust-cache@v1
|
||||
- uses: Swatinem/rust-cache@842ef286fff290e445b90b4002cc9807c3669641 # 1.3.0
|
||||
with:
|
||||
key: x86_64-unknown-linux-gnu-deb
|
||||
|
||||
@@ -349,7 +349,7 @@ jobs:
|
||||
ls ./release
|
||||
|
||||
- name: Delete tag and release
|
||||
uses: dev-drprasad/delete-tag-and-release@v0.1.3
|
||||
uses: dev-drprasad/delete-tag-and-release@085c6969f18bad0de1b9f3fe6692a3cd01f64fe5 # 0.2.0
|
||||
if: github.event.inputs.isMock != 'mock'
|
||||
with:
|
||||
delete_release: true
|
||||
@@ -362,7 +362,7 @@ jobs:
|
||||
if: github.event.inputs.isMock != 'mock'
|
||||
|
||||
- name: Upload all saved release files if not mock
|
||||
uses: softprops/action-gh-release@v1
|
||||
uses: softprops/action-gh-release@17cd0d34deddf848fc0e7d9be5202c148c270a0a # 0.1.14
|
||||
if: github.event.inputs.isMock != 'mock'
|
||||
with:
|
||||
token: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
@@ -10,7 +10,7 @@ jobs:
|
||||
should_skip: ${{ steps.skip_check.outputs.should_skip }}
|
||||
steps:
|
||||
- id: skip_check
|
||||
uses: fkirc/skip-duplicate-actions@master
|
||||
uses: fkirc/skip-duplicate-actions@38c3738dcac87b41e2b7038775457756c793566e # https://github.com/fkirc/skip-duplicate-actions/commit/38c3738dcac87b41e2b7038775457756c793566e
|
||||
with:
|
||||
skip_after_successful_duplicate: "true"
|
||||
paths: '["docs/**", ".github/workflows/docs.yml"]'
|
||||
|
||||
Reference in New Issue
Block a user