mirror of
https://github.com/S7NetPlus/s7netplus.git
synced 2026-02-17 22:38:27 +08:00
Compare commits
1 Commits
gh-actions
...
dependabot
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
197bea8a1d |
29
.github/workflows/dotnet.yml
vendored
29
.github/workflows/dotnet.yml
vendored
@@ -19,6 +19,10 @@ env:
|
||||
DOTNET_NOLOGO: true
|
||||
NuGetDirectory: ${{ github.workspace}}/nuget
|
||||
|
||||
defaults:
|
||||
run:
|
||||
shell: pwsh
|
||||
|
||||
jobs:
|
||||
create_nuget:
|
||||
runs-on: ubuntu-latest
|
||||
@@ -27,17 +31,10 @@ jobs:
|
||||
with:
|
||||
fetch-depth: 0 # Get all history to allow automatic versioning
|
||||
|
||||
- name: Setup .NET
|
||||
uses: actions/setup-dotnet@v3
|
||||
with:
|
||||
dotnet-version: |
|
||||
6.x
|
||||
7.x
|
||||
|
||||
- name: Install GitVersion
|
||||
uses: gittools/actions/gitversion/setup@v0
|
||||
with:
|
||||
versionSpec: '6.0.x'
|
||||
versionSpec: '6.x'
|
||||
includePrerelease: true
|
||||
preferLatestVersion: true
|
||||
|
||||
@@ -45,6 +42,9 @@ jobs:
|
||||
id: gitversion
|
||||
uses: gittools/actions/gitversion/execute@v0
|
||||
|
||||
- name: Setup .NET
|
||||
uses: actions/setup-dotnet@v3
|
||||
|
||||
- run: >
|
||||
dotnet pack
|
||||
--configuration Release
|
||||
@@ -54,7 +54,7 @@ jobs:
|
||||
/p:PackageVersion=${{ steps.gitversion.outputs.semVer }}
|
||||
--output ${{ env.NuGetDirectory }}
|
||||
|
||||
- uses: actions/upload-artifact@v4
|
||||
- uses: actions/upload-artifact@v3
|
||||
with:
|
||||
name: nuget
|
||||
if-no-files-found: error
|
||||
@@ -71,21 +71,21 @@ jobs:
|
||||
artifacts: ${{ github.workspace }}/artifacts
|
||||
strategy:
|
||||
matrix:
|
||||
os: [windows-latest, ubuntu-latest, macos-13]
|
||||
os: [windows-latest, ubuntu-20.04, macos-latest]
|
||||
fail-fast: false
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
|
||||
- name: Install Snap7 Linux
|
||||
if: ${{ matrix.os == 'ubuntu-latest' }}
|
||||
if: ${{ matrix.os == 'ubuntu-20.04' }}
|
||||
run: |
|
||||
sudo add-apt-repository ppa:gijzelaar/snap7 -y
|
||||
sudo add-apt-repository ppa:gijzelaar/snap7
|
||||
sudo apt-get update
|
||||
sudo apt-get install libsnap7-1 libsnap7-dev
|
||||
|
||||
- name: Install Snap7 MacOs
|
||||
if: ${{ matrix.os == 'macos-13' }}
|
||||
if: ${{ matrix.os == 'macos-latest' }}
|
||||
run: |
|
||||
brew install snap7
|
||||
|
||||
@@ -97,7 +97,6 @@ jobs:
|
||||
7.x
|
||||
|
||||
- name: Nuget Cache
|
||||
if: ${{ !env.ACT }}
|
||||
uses: actions/cache@v3
|
||||
with:
|
||||
path: ~/.nuget/packages
|
||||
@@ -117,7 +116,7 @@ jobs:
|
||||
runs-on: ubuntu-latest
|
||||
needs: [ create_nuget, run_test ]
|
||||
steps:
|
||||
- uses: actions/download-artifact@v4
|
||||
- uses: actions/download-artifact@v4.1.7
|
||||
with:
|
||||
name: nuget
|
||||
path: ${{ env.NuGetDirectory }}
|
||||
|
||||
Reference in New Issue
Block a user