Skip to content

Commit 737a722

Browse files
committed
Move published release installation test to new workflow
So that it can be triggered from the `release` workflow (as they have been since GitoxideLabs#1555), as well as directly. This is to make it easier to run or rerun the published crate installation tests, as well as any future such tests that may be added, without having to run jobs that are involved in making the release.
1 parent f52336f commit 737a722

File tree

2 files changed

+48
-38
lines changed

2 files changed

+48
-38
lines changed

.github/workflows/release-check.yml

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
name: Test published release
2+
3+
on: [ workflow_call, workflow_dispatch ]
4+
5+
permissions:
6+
contents: read
7+
8+
jobs:
9+
installation:
10+
strategy:
11+
matrix:
12+
build: [ win-msvc, win-gnu, win32-msvc, win32-gnu ]
13+
include:
14+
- build: win-msvc
15+
os: windows-latest
16+
rust: stable
17+
target: x86_64-pc-windows-msvc
18+
- build: win-gnu
19+
os: windows-latest
20+
rust: stable-x86_64-gnu
21+
target: x86_64-pc-windows-gnu
22+
- build: win32-msvc
23+
os: windows-latest
24+
rust: stable
25+
target: i686-pc-windows-msvc
26+
- build: win32-gnu
27+
os: windows-latest
28+
rust: stable
29+
target: i686-pc-windows-gnu
30+
31+
runs-on: ${{ matrix.os }}
32+
33+
steps:
34+
- uses: actions/checkout@v4
35+
- name: Install Rust
36+
uses: dtolnay/rust-toolchain@master
37+
with:
38+
toolchain: ${{ matrix.rust }}
39+
targets: ${{ matrix.target }}
40+
- uses: msys2/setup-msys2@v2
41+
with:
42+
msystem: MINGW${{ startsWith(matrix.target, 'i686-') && '32' || '64' }}
43+
pacboy: cc:p
44+
path-type: inherit
45+
- name: 'Installation from crates.io: gitoxide'
46+
run: cargo +${{ matrix.rust }} install --target ${{ matrix.target }} --no-default-features --features max-pure --target-dir install-artifacts --debug --force gitoxide
47+
shell: msys2 {0}

.github/workflows/release.yml

Lines changed: 1 addition & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -512,41 +512,4 @@ jobs:
512512
}' -F discussionId="$DISCUSSION_ID" -F body="$comment_body"
513513
514514
installation:
515-
strategy:
516-
matrix:
517-
build: [ win-msvc, win-gnu, win32-msvc, win32-gnu ]
518-
include:
519-
- build: win-msvc
520-
os: windows-latest
521-
rust: stable
522-
target: x86_64-pc-windows-msvc
523-
- build: win-gnu
524-
os: windows-latest
525-
rust: stable-x86_64-gnu
526-
target: x86_64-pc-windows-gnu
527-
- build: win32-msvc
528-
os: windows-latest
529-
rust: stable
530-
target: i686-pc-windows-msvc
531-
- build: win32-gnu
532-
os: windows-latest
533-
rust: stable
534-
target: i686-pc-windows-gnu
535-
536-
runs-on: ${{ matrix.os }}
537-
538-
steps:
539-
- uses: actions/checkout@v4
540-
- name: Install Rust
541-
uses: dtolnay/rust-toolchain@master
542-
with:
543-
toolchain: ${{ matrix.rust }}
544-
targets: ${{ matrix.target }}
545-
- uses: msys2/setup-msys2@v2
546-
with:
547-
msystem: MINGW${{ startsWith(matrix.target, 'i686-') && '32' || '64' }}
548-
pacboy: cc:p
549-
path-type: inherit
550-
- name: 'Installation from crates.io: gitoxide'
551-
run: cargo +${{ matrix.rust }} install --target ${{ matrix.target }} --no-default-features --features max-pure --target-dir install-artifacts --debug --force gitoxide
552-
shell: msys2 {0}
515+
uses: ./.github/workflows/release-check.yml

0 commit comments

Comments
 (0)