Skip to content

Commit

Permalink
WIP5 stop hardcoding version
Browse files Browse the repository at this point in the history
  • Loading branch information
knocte committed Mar 29, 2024
1 parent 9bd7784 commit 53393cc
Showing 1 changed file with 14 additions and 12 deletions.
26 changes: 14 additions & 12 deletions .github/workflows/dotnet.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,8 @@ jobs:
push:
needs: build
runs-on: ubuntu-22.04
env:
BASE_VERSION: 4.20.0

steps:
- name: Checkout code
Expand All @@ -40,25 +42,25 @@ jobs:
run: |
dotnet new classlib -n Nethereum --framework netstandard2.0
cd Nethereum
dotnet add package --version 4.20.0 Nethereum.ABI
dotnet add package --version 4.20.0 Nethereum.Accounts
dotnet add package --version 4.20.0 Nethereum.Contracts
dotnet add package --version 4.20.0 Nethereum.Hex
dotnet add package --version 4.20.0 Nethereum.KeyStore
dotnet add package --version 4.20.0 Nethereum.RLP
dotnet add package --version 4.20.0 Nethereum.RPC
dotnet add package --version 4.20.0 Nethereum.Signer
dotnet add package --version 4.20.0 Nethereum.StandardTokenEIP20
dotnet add package --version 4.20.0 Nethereum.Util
dotnet add package --version 4.20.0 Nethereum.Web3
dotnet add package --version $env:BASE_VERSION Nethereum.ABI
dotnet add package --version $env:BASE_VERSION Nethereum.Accounts
dotnet add package --version $env:BASE_VERSION Nethereum.Contracts
dotnet add package --version $env:BASE_VERSION Nethereum.Hex
dotnet add package --version $env:BASE_VERSION Nethereum.KeyStore
dotnet add package --version $env:BASE_VERSION Nethereum.RLP
dotnet add package --version $env:BASE_VERSION Nethereum.RPC
dotnet add package --version $env:BASE_VERSION Nethereum.Signer
dotnet add package --version $env:BASE_VERSION Nethereum.StandardTokenEIP20
dotnet add package --version $env:BASE_VERSION Nethereum.Util
dotnet add package --version $env:BASE_VERSION Nethereum.Web3
rm Class1.cs
- name: Pack
run: |
cd Nethereum
DATE=$(date +%Y%m%d-%H%M)
GIT_COMMIT=$(git rev-parse --short HEAD)
VERSION="1.0.0+$DATE.$GIT_COMMIT"
VERSION="$env:BASE_VERSION+$DATE.$GIT_COMMIT"
dotnet pack -c Release -o ../dist -p:IncludeBuildOutput=false -p:IncludeContentInPack=false -p:TargetFrameworks=netstandard2.0 -p:Version=$VERSION
# disabled for now, comes from https://github.com/Mersho/Nethereum/commits/NethMetapackage
Expand Down

0 comments on commit 53393cc

Please sign in to comment.