Skip to content

Commit

Permalink
Merge pull request #2 from fusioninventory/ci-build
Browse files Browse the repository at this point in the history
Fix CI for build
  • Loading branch information
ddurieux authored Jun 17, 2024
2 parents 155bf98 + 203a0ee commit 45965ca
Show file tree
Hide file tree
Showing 8 changed files with 2,767 additions and 19 deletions.
33 changes: 21 additions & 12 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
@@ -1,34 +1,42 @@
name: Build release

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

jobs:
release:
name: Release - ${{ matrix.platform.release_for }}
strategy:
matrix:
platform:
- release_for: FreeBSD-x86_64
os: ubuntu-20.04
os: ubuntu-latest
target: x86_64-unknown-freebsd
bin: precious
bin: fusioninventory-agent
name: fusioninventory-agent-FreeBSD-x86_64.tar.gz
command: build

- release_for: Windows-x86_64
os: windows-latest
target: x86_64-pc-windows-msvc
bin: precious.exe
bin: fusioninventory-agent.exe
name: fusioninventory-agent-Windows-x86_64.zip
command: both

- release_for: macOS-x86_64
os: macOS-latest
target: x86_64-apple-darwin
bin: precious
name: fusioninventory-agent-Darwin-x86_64.tar.gz
command: both
# - release_for: macOS-x86_64
# os: macOS-latest
# target: x86_64-apple-darwin
# bin: fusioninventory-agent
# name: fusioninventory-agent-Darwin-x86_64.tar.gz
# command: both

- release_for: Linux-x86_64
os: ubuntu-20.04
os: ubuntu-latest
target: x86_64-unknown-linux-gnu
bin: precious
bin: fusioninventory-agent
name: fusioninventory-agent-Linux-x86_64.tar.gz
command: build

Expand All @@ -42,4 +50,5 @@ jobs:
command: ${{ matrix.platform.command }}
target: ${{ matrix.platform.target }}
args: "--locked --release"
strip: true
cross-version: "19be83481fd3e50ea103d800d72e0f8eddb1c90c"
strip: true
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ target/

# Remove Cargo.lock from gitignore if creating an executable, leave it for libraries
# More information here https://doc.rust-lang.org/cargo/guide/cargo-toml-vs-cargo-lock.html
Cargo.lock
# Cargo.lock

# These are backup files generated by rustfmt
**/*.rs.bk
Expand Down
Loading

0 comments on commit 45965ca

Please sign in to comment.