mirror of
https://github.com/hashcat/hashcat.git
synced 2024-11-22 08:08:10 +00:00
Optimize github workflow
This commit is contained in:
parent
d6b50c7d0b
commit
620731c8e8
77
.github/workflows/build.yml
vendored
77
.github/workflows/build.yml
vendored
@ -41,53 +41,36 @@ on:
|
|||||||
- '.github/workflows/build.yml'
|
- '.github/workflows/build.yml'
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build-linux:
|
build:
|
||||||
strategy:
|
strategy:
|
||||||
fail-fast: false
|
fail-fast: false
|
||||||
matrix:
|
matrix:
|
||||||
shared: [0, 1]
|
include:
|
||||||
name: Build Linux (${{ matrix.shared == 0 && 'Static' || 'Shared' }})
|
- os: ubuntu-latest
|
||||||
runs-on: ubuntu-latest
|
os_name: linux
|
||||||
|
shared: 0
|
||||||
|
- os: ubuntu-latest
|
||||||
|
os_name: linux
|
||||||
|
shared: 1
|
||||||
|
- os: macos-latest
|
||||||
|
os_name: macos
|
||||||
|
shared: 0
|
||||||
|
- os: macos-latest
|
||||||
|
os_name: macos
|
||||||
|
shared: 1
|
||||||
|
- os: windows-latest
|
||||||
|
os_name: windows
|
||||||
|
shared: 0
|
||||||
|
- os: windows-latest
|
||||||
|
os_name: windows
|
||||||
|
shared: 1
|
||||||
|
name: Build ${{ matrix.os_name }} (${{ matrix.shared == 0 && 'Static' || 'Shared' }})
|
||||||
|
runs-on: ${{ matrix.os }}
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v4
|
||||||
- name: Build
|
|
||||||
env:
|
|
||||||
SHARED: ${{ matrix.shared }}
|
|
||||||
run: make
|
|
||||||
- name: Generate artifacts
|
|
||||||
uses: actions/upload-artifact@v4
|
|
||||||
with:
|
|
||||||
name: hashcat-linux-${{ matrix.shared == 0 && 'static' || 'shared' }}
|
|
||||||
path: ${{ env.include_paths }}
|
|
||||||
|
|
||||||
build-macos:
|
- name: Install dependencies (Windows only)
|
||||||
strategy:
|
if: matrix.os_name == 'windows'
|
||||||
fail-fast: false
|
|
||||||
matrix:
|
|
||||||
shared: [0, 1]
|
|
||||||
name: Build macOS (${{ matrix.shared == 0 && 'Static' || 'Shared' }})
|
|
||||||
runs-on: macos-latest
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@v4
|
|
||||||
- name: Build
|
|
||||||
env:
|
|
||||||
SHARED: ${{ matrix.shared }}
|
|
||||||
run: make
|
|
||||||
- name: Generate artifacts
|
|
||||||
uses: actions/upload-artifact@v4
|
|
||||||
with:
|
|
||||||
name: hashcat-macos-${{ matrix.shared == 0 && 'static' || 'shared' }}
|
|
||||||
path: ${{ env.include_paths }}
|
|
||||||
|
|
||||||
build-windows:
|
|
||||||
strategy:
|
|
||||||
fail-fast: false
|
|
||||||
matrix:
|
|
||||||
shared: [0, 1]
|
|
||||||
name: Build Windows (${{ matrix.shared == 0 && 'Static' || 'Shared' }})
|
|
||||||
runs-on: windows-latest
|
|
||||||
steps:
|
|
||||||
- name: Install libiconv
|
|
||||||
uses: msys2/setup-msys2@v2
|
uses: msys2/setup-msys2@v2
|
||||||
with:
|
with:
|
||||||
update: true
|
update: true
|
||||||
@ -97,14 +80,22 @@ jobs:
|
|||||||
libiconv
|
libiconv
|
||||||
libiconv-devel
|
libiconv-devel
|
||||||
make
|
make
|
||||||
- uses: actions/checkout@v4
|
|
||||||
- name: Build
|
- name: Build
|
||||||
|
if: matrix.os_name == 'windows'
|
||||||
shell: msys2 {0}
|
shell: msys2 {0}
|
||||||
env:
|
env:
|
||||||
SHARED: ${{ matrix.shared }}
|
SHARED: ${{ matrix.shared }}
|
||||||
run: make
|
run: make
|
||||||
|
|
||||||
|
- name: Build
|
||||||
|
if: matrix.os_name != 'windows'
|
||||||
|
env:
|
||||||
|
SHARED: ${{ matrix.shared }}
|
||||||
|
run: make
|
||||||
|
|
||||||
- name: Generate artifacts
|
- name: Generate artifacts
|
||||||
uses: actions/upload-artifact@v4
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: hashcat-windows-${{ matrix.shared == 0 && 'static' || 'shared' }}
|
name: hashcat-${{ matrix.os_name }}-${{ matrix.shared == 0 && 'static' || 'shared' }}
|
||||||
path: ${{ env.include_paths }}
|
path: ${{ env.include_paths }}
|
||||||
|
Loading…
Reference in New Issue
Block a user