fix: 更正一些cmd命令的处理方式,使测试htop数据正常显示 #71
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: build | |
on: | |
push: | |
paths: | |
- 'llcomNext/**' | |
- '.github/workflows/build.yml' | |
workflow_dispatch: | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
# build and publish in parallel: linux-arm,linux-x64,win-x86,win-x64,osx-x64 | |
dotnetos: [linux, win, osx] | |
dotnetarch: [x86, x64, arm, arm64] | |
exclude: | |
- dotnetos: linux | |
dotnetarch: x86 | |
- dotnetos: osx | |
dotnetarch: x86 | |
- dotnetos: osx | |
dotnetarch: arm | |
- dotnetos: win | |
dotnetarch: arm | |
fail-fast: true | |
steps: | |
- uses: actions/checkout@v4 | |
- name: environment prepare | |
run: | | |
sudo apt-get update | |
sudo apt-get install -y apt-transport-https | |
sudo apt-get update | |
sudo apt-get install -y dotnet-sdk-8.0 | |
sudo apt-get install -y p7zip-full | |
- name: build | |
env: | |
DOTNETOS: ${{ matrix.dotnetos }} | |
DOTNETARCH: ${{ matrix.dotnetarch }} | |
run: | | |
cd llcomNext/LLCOM | |
dotnet publish -r $DOTNETOS-$DOTNETARCH --configuration Release -p:PublishSingleFile=true -p:IncludeNativeLibrariesForSelfExtract=true --self-contained true -p:PublishTrimmed=true -p:TrimMode=link | |
mkdir pkg | |
mv bin/Release/net8.0/$DOTNETOS-$DOTNETARCH/publish/* pkg/ | |
if [[ "$DOTNETOS-$DOTNETARCH" =~ "win-" ]]; then :; else mv pkg/ llcom/; tar -cvf llcom.tar llcom/; mkdir pkg; mv llcom.tar pkg/; fi | |
- uses: actions/upload-artifact@v4 | |
with: | |
name: llcomNext-${{ matrix.dotnetos }}-${{ matrix.dotnetarch }} | |
path: llcomNext/LLCOM/pkg/ |