mirror of
https://github.com/ouch-org/ouch.git
synced 2025-06-07 20:15:27 +00:00
CI: refac: reorganizing + renaming
This commit is contained in:
parent
1d70a810e5
commit
1c6fb9a0b3
91
.github/workflows/build-and-test.yml
vendored
91
.github/workflows/build-and-test.yml
vendored
@ -1,4 +1,4 @@
|
|||||||
name: build-and-test
|
name: PR checks
|
||||||
|
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
@ -9,14 +9,54 @@ on:
|
|||||||
pull_request:
|
pull_request:
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
clippy-rustfmt:
|
||||||
name: build
|
name: clippy-rustfmt
|
||||||
runs-on: ${{ matrix.os }}
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- name: Checkout
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
|
||||||
|
- name: "Cargo: clippy, fmt"
|
||||||
|
run: |
|
||||||
|
rustup toolchain install stable --profile minimal -c clippy
|
||||||
|
rustup toolchain install nightly --profile minimal -c rustfmt
|
||||||
|
cargo +stable clippy -- -D warnings
|
||||||
|
cargo +nightly fmt -- --check
|
||||||
|
|
||||||
|
github-release:
|
||||||
|
name: github-release
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/')
|
||||||
|
needs: build-and-test
|
||||||
|
steps:
|
||||||
|
- name: Checkout
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
|
||||||
|
- name: Download artifacts
|
||||||
|
uses: dawidd6/action-download-artifact@v3
|
||||||
|
with:
|
||||||
|
path: artifacts
|
||||||
|
|
||||||
|
- name: Package release assets
|
||||||
|
run: scripts/package-release-assets.sh
|
||||||
|
|
||||||
|
- name: Create release
|
||||||
|
uses: softprops/action-gh-release@v2
|
||||||
|
with:
|
||||||
|
draft: true
|
||||||
|
files: release/ouch-*
|
||||||
|
|
||||||
|
build-and-test:
|
||||||
|
name: build-and-test
|
||||||
|
runs-on: ${{ matrix.os || 'ubuntu-latest' }}
|
||||||
env:
|
env:
|
||||||
CARGO: cargo
|
CARGO: cargo
|
||||||
strategy:
|
strategy:
|
||||||
fail-fast: false
|
fail-fast: false
|
||||||
matrix:
|
matrix:
|
||||||
|
feature-use-zlib: [true, false]
|
||||||
|
feature-use-zstd-thin: [true, false]
|
||||||
|
feature-unrar: [true, false]
|
||||||
target:
|
target:
|
||||||
# native
|
# native
|
||||||
- x86_64-unknown-linux-gnu
|
- x86_64-unknown-linux-gnu
|
||||||
@ -30,13 +70,8 @@ jobs:
|
|||||||
- aarch64-unknown-linux-musl
|
- aarch64-unknown-linux-musl
|
||||||
- armv7-unknown-linux-gnueabihf
|
- armv7-unknown-linux-gnueabihf
|
||||||
- armv7-unknown-linux-musleabihf
|
- armv7-unknown-linux-musleabihf
|
||||||
feature-use-zlib: [true, false]
|
|
||||||
feature-use-zstd-thin: [true, false]
|
|
||||||
feature-unrar: [true, false]
|
|
||||||
|
|
||||||
include:
|
include:
|
||||||
# default runner
|
|
||||||
- os: ubuntu-latest
|
|
||||||
# runner overrides
|
# runner overrides
|
||||||
- target: x86_64-pc-windows-gnu
|
- target: x86_64-pc-windows-gnu
|
||||||
os: windows-latest
|
os: windows-latest
|
||||||
@ -121,41 +156,3 @@ jobs:
|
|||||||
target/${{ matrix.target }}/release/ouch
|
target/${{ matrix.target }}/release/ouch
|
||||||
target/${{ matrix.target }}/release/ouch.exe
|
target/${{ matrix.target }}/release/ouch.exe
|
||||||
artifacts/
|
artifacts/
|
||||||
|
|
||||||
clippy-rustfmt:
|
|
||||||
name: clippy-rustfmt
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- name: Checkout
|
|
||||||
uses: actions/checkout@v4
|
|
||||||
|
|
||||||
- name: "Cargo: clippy, fmt"
|
|
||||||
run: |
|
|
||||||
rustup toolchain install stable --profile minimal -c clippy
|
|
||||||
rustup toolchain install nightly --profile minimal -c rustfmt
|
|
||||||
cargo +stable clippy -- -D warnings
|
|
||||||
cargo +stable clippy --tests -- -D warnings
|
|
||||||
cargo +nightly fmt -- --check
|
|
||||||
|
|
||||||
github-release:
|
|
||||||
name: github-release
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/')
|
|
||||||
needs: build
|
|
||||||
steps:
|
|
||||||
- name: Checkout
|
|
||||||
uses: actions/checkout@v4
|
|
||||||
|
|
||||||
- name: Download artifacts
|
|
||||||
uses: dawidd6/action-download-artifact@v3
|
|
||||||
with:
|
|
||||||
path: artifacts
|
|
||||||
|
|
||||||
- name: Package release assets
|
|
||||||
run: scripts/package-release-assets.sh
|
|
||||||
|
|
||||||
- name: Create release
|
|
||||||
uses: softprops/action-gh-release@v2
|
|
||||||
with:
|
|
||||||
draft: true
|
|
||||||
files: release/ouch-*
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user