mirror of
https://github.com/lsd-rs/lsd
synced 2024-12-14 14:12:31 +00:00
maint/cicd ~ add GitHub Actions (GHA) workflow (build and deploy)
This commit is contained in:
parent
9c3db9b838
commit
a85dc11a47
1 changed files with 65 additions and 0 deletions
65
.github/workflows/CD.yml
vendored
Normal file
65
.github/workflows/CD.yml
vendored
Normal file
|
@ -0,0 +1,65 @@
|
||||||
|
name: CD
|
||||||
|
|
||||||
|
# spell-checker:ignore musl executables toolchain MSVC
|
||||||
|
|
||||||
|
on: [push, pull_request]
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build_linux:
|
||||||
|
name: Build (linux)
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
strategy:
|
||||||
|
fail-fast: false
|
||||||
|
matrix:
|
||||||
|
target:
|
||||||
|
- i686-unknown-linux-gnu
|
||||||
|
- x86_64-unknown-linux-gnu
|
||||||
|
- x86_64-unknown-linux-musl
|
||||||
|
# - i686-pc-windows-gnu
|
||||||
|
# - x86_64-pc-windows-gnu
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v1
|
||||||
|
- uses: actions-rs/toolchain@v1
|
||||||
|
with:
|
||||||
|
toolchain: stable
|
||||||
|
target: ${{ matrix.target }}
|
||||||
|
override: true
|
||||||
|
- uses: actions-rs/cargo@v1
|
||||||
|
with:
|
||||||
|
use-cross: true
|
||||||
|
command: build
|
||||||
|
args: --release --target=${{ matrix.target }}
|
||||||
|
- name: Archive executables as artifacts
|
||||||
|
uses: actions/upload-artifact@master
|
||||||
|
with:
|
||||||
|
name: lsd-${{ matrix.target }}
|
||||||
|
path: target/${{ matrix.target }}/release/lsd
|
||||||
|
|
||||||
|
build_windows:
|
||||||
|
name: Build (windows)
|
||||||
|
runs-on: windows-latest
|
||||||
|
strategy:
|
||||||
|
fail-fast: false
|
||||||
|
matrix:
|
||||||
|
target:
|
||||||
|
# - i686-pc-windows-gnu
|
||||||
|
- i686-pc-windows-msvc
|
||||||
|
# - x86_64-pc-windows-gnu
|
||||||
|
- x86_64-pc-windows-msvc
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v1
|
||||||
|
- uses: actions-rs/toolchain@v1
|
||||||
|
with:
|
||||||
|
toolchain: stable
|
||||||
|
target: ${{ matrix.target }}
|
||||||
|
override: true
|
||||||
|
- uses: actions-rs/cargo@v1
|
||||||
|
with:
|
||||||
|
use-cross: true
|
||||||
|
command: build
|
||||||
|
args: --release --target=${{ matrix.target }}
|
||||||
|
- name: Archive executables as artifacts
|
||||||
|
uses: actions/upload-artifact@master
|
||||||
|
with:
|
||||||
|
name: lsd-${{ matrix.target }}.exe
|
||||||
|
path: target/${{ matrix.target }}/release/lsd.exe
|
Loading…
Reference in a new issue