Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
45 changes: 45 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
name: Build

on:
workflow_call:

env:
CARGO_TERM_COLOR: always

jobs:
linux:
name: Linux
runs-on: ubuntu-latest
container: rust:1.75-slim
steps:
- uses: actions/checkout@v4
- run: apt-get update && apt-get install -y pkg-config libssl-dev
- run: cargo build --release
- uses: actions/upload-artifact@v4
with:
name: gitclaw-linux
path: target/release/gitclaw

macos:
name: macOS
runs-on: macos-latest
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@1.75
- run: cargo build --release
- uses: actions/upload-artifact@v4
with:
name: gitclaw-macos
path: target/release/gitclaw

windows:
name: Windows
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@1.75
- run: cargo build --release
- uses: actions/upload-artifact@v4
with:
name: gitclaw-windows
path: target/release/gitclaw.exe
67 changes: 0 additions & 67 deletions .github/workflows/ci.yml

This file was deleted.

19 changes: 19 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
name: Main

on:
push:
branches: [main, master]
pull_request:
branches: [main, master]

jobs:
Verify:
uses: ./.github/workflows/verify.yml

Test:
needs: Verify
uses: ./.github/workflows/test.yml

Build:
needs: Test
uses: ./.github/workflows/build.yml
33 changes: 33 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: Test

on:
workflow_call:

env:
CARGO_TERM_COLOR: always

jobs:
linux:
name: Linux
runs-on: ubuntu-latest
container: rust:1.75-slim
steps:
- uses: actions/checkout@v4
- run: apt-get update && apt-get install -y pkg-config libssl-dev
- run: cargo test

macos:
name: macOS
runs-on: macos-latest
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@1.75
- run: cargo test

windows:
name: Windows
runs-on: windows-latest
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@1.75
- run: cargo test
27 changes: 27 additions & 0 deletions .github/workflows/verify.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: Verify

on:
workflow_call:

env:
CARGO_TERM_COLOR: always

jobs:
Format:
name: Format
runs-on: ubuntu-latest
container: rust:1.75-slim
steps:
- uses: actions/checkout@v4
- run: rustup component add rustfmt
- run: cargo fmt --check

Clippy:
name: Clippy
runs-on: ubuntu-latest
container: rust:1.75-slim
steps:
- uses: actions/checkout@v4
- run: apt-get update && apt-get install -y pkg-config libssl-dev
- run: rustup component add clippy
- run: cargo clippy -- -D warnings
2 changes: 1 addition & 1 deletion tests/error_handling.rs
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ fn test_find_matching_asset_empty_assets() {
/// Test asset matching with only checksum files
#[test]
fn test_find_matching_asset_only_checksums() {
use gitclaw::github::{Asset, find_matching_asset, Platform, Release};
use gitclaw::github::{find_matching_asset, Asset, Platform, Release};

let release = Release {
tag_name: "v1.0.0".to_string(),
Expand Down
Loading