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
210 changes: 0 additions & 210 deletions .editorconfig

This file was deleted.

23 changes: 15 additions & 8 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,21 +11,28 @@ on:

jobs:
build:
name: ${{ matrix.target }}

strategy:
matrix:
os: [windows-latest, macos-latest]
include:
- target: x86_64-pc-windows-msvc
os: windows-latest
- target: x86_64-apple-darwin
os: macos-13
- target: aarch64-apple-darwin
os: macos-latest

runs-on: ${{ matrix.os }}

steps:
- uses: actions/checkout@v4
- name: Setup .NET
uses: actions/setup-dotnet@v4
- uses: dtolnay/rust-toolchain@master
with:
dotnet-version: 8.0.x
- name: Restore dependencies
run: dotnet restore
toolchain: stable
target: ${{ matrix.target }}
- name: Build
run: dotnet build --no-restore
run:
cargo build --all --target ${{ matrix.target }}
- name: Test
run: dotnet test --no-build --verbosity normal
run: cargo test --all --target ${{ matrix.target }}
43 changes: 28 additions & 15 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
# This workflow will build a .NET project
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-net

name: Release

on:
Expand All @@ -9,32 +6,48 @@ on:

jobs:
release:
name: ${{ matrix.target }}

permissions:
contents: write

strategy:
matrix:
include:
- target: x86_64-pc-windows-msvc
os: windows-latest
- target: x86_64-apple-darwin
os: macos-13
- target: aarch64-apple-darwin
os: macos-latest

runs-on: ubuntu-latest
runs-on: ${{ matrix.os }}

steps:
- uses: actions/checkout@v4
- name: Setup .NET
uses: actions/setup-dotnet@v4
- uses: dtolnay/rust-toolchain@master
with:
dotnet-version: 8.0.x
- name: Publish
toolchain: stable
target: ${{ matrix.target }}
- name: Build
run: |
dotnet publish src -r win-x64
dotnet publish src -r osx-x64
dotnet publish src -r osx-arm64
cargo build --release --target ${{ matrix.target }}

if [ "${{ matrix.os }}" = "windows-latest" ]; then
bin="target/${{ matrix.target }}/release/livetagger.exe"
else
bin="target/${{ matrix.target }}/release/livetagger"
fi

echo "BIN=$bin" >> $GITHUB_ENV
- name: Zip artifacts
run: |
tag=$(git describe --tags --abbrev=0)

7z a "livetagger-$tag-win-x64.zip" "./src/bin/Release/net8.0/win-x64/publish/*"
7z a "livetagger-$tag-osx-x64.zip" "./src/bin/Release/net8.0/osx-x64/publish/*"
7z a "livetagger-$tag-osx-arm64.zip" "./src/bin/Release/net8.0/osx-arm64/publish/*"
7z a "livetagger-$tag-$target-x64.zip" $bin
- name: Publish
uses: softprops/action-gh-release@v2
with:
files: "livetagger*"
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
Loading