Skip to content

修改包说明

修改包说明 #413

name: Building and Packaging
on:
push:
branches: [ "master" ]
paths: [IoTSharp.*/**,IoTSharp/**,ClientApp/**]
jobs:
build:
strategy:
matrix:
configuration: [Release]
publish_profile: [win7-x64,linux-x64,osx-x64,linux-arm64,linux-arm] # https://docs.microsoft.com/en-us/dotnet/core/rid-catalog
runs-on: windows-latest
env:
Solution_Name: IoTSharp.sln
steps:
- name: Checkout
uses: actions/checkout@v3
with:
fetch-depth: 0
submodules: 'true'
# Install the .NET Core workload
- name: Install .NET Core
uses: actions/setup-dotnet@v3
with:
dotnet-version: 7.0.x
# Add MSBuild to the PATH: https://github.com/microsoft/setup-msbuild
- name: Setup MSBuild.exe
uses: microsoft/setup-msbuild@v1.1
# Restore the application to populate the obj folder with RuntimeIdentifiers
- name: Restore the application
run: msbuild $env:Solution_Name /t:Restore /p:Configuration=$env:Configuration
env:
Configuration: ${{ matrix.configuration }}
# Create the app package by building and packaging the Windows Application Packaging project
# npm config set registry https://registry.npmmirror.com
- name: Building and Packaging
run: |
set NODE_OPTIONS=--openssl-legacy-provider
dotnet build IoTSharp.sln -c $env:Configuration /p:DeployOnBuild=true /p:PublishProfile=$env:PublishProfile
env:
Configuration: ${{ matrix.configuration }}
PublishProfile: ${{ matrix.publish_profile }}
# Upload the package: https://github.com/marketplace/actions/upload-a-build-artifact
- name: Upload build artifacts
uses: actions/upload-artifact@v3
with:
name: IoTSharp ${{ matrix.configuration }} ${{ matrix.publish_profile }}
path: IoTSharp\bin\publish