diff --git a/.github/workflows/deployment.yml b/.github/workflows/deployment.yml new file mode 100644 index 0000000..92f21bc --- /dev/null +++ b/.github/workflows/deployment.yml @@ -0,0 +1,33 @@ +name: Deployment + +on: + workflow_dispatch: + inputs: + version: + description: 'Plugin Version (SemVer: https://semver.org)' + required: true +jobs: + deploy: + name: "NuGet Deployment" + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + name: Checkout Repository + with: + fetch-depth: 0 + - name: Setup .NET + uses: actions/setup-dotnet@v1 + with: + dotnet-version: 5.0.x + - name: Install dependencies + run: dotnet restore + - name: Update version + run: "sed -i \"s#0.0.0#${{ github.event.inputs.version }}#\" Feli.OpenMod.AdvancedCosmetics/Feli.OpenMod.AdvancedCosmetics.csproj" + - name: Update assembly version + run: "sed -i \"s#0.0.0#${{ github.event.inputs.version }}#\" Feli.OpenMod.AdvancedCosmetics/Feli.OpenMod.AdvancedCosmetics.csproj" + - name: Build + run: dotnet build Feli.OpenMod.AdvancedCosmetics/Feli.OpenMod.AdvancedCosmetics.csproj --configuration Release --no-restore + - name: Push to NuGet + run: dotnet nuget push Feli.OpenMod.AdvancedCosmetics/bin/Release/*.nupkg + --api-key ${{ secrets.NUGET_DEPLOY_KEY }} + --source https://api.nuget.org/v3/index.json \ No newline at end of file diff --git a/Feli.OpenMod.AdvancedCosmetics/Feli.OpenMod.AdvancedCosmetics.csproj b/Feli.OpenMod.AdvancedCosmetics/Feli.OpenMod.AdvancedCosmetics.csproj index e7d1d3f..dcf9a26 100644 --- a/Feli.OpenMod.AdvancedCosmetics/Feli.OpenMod.AdvancedCosmetics.csproj +++ b/Feli.OpenMod.AdvancedCosmetics/Feli.OpenMod.AdvancedCosmetics.csproj @@ -3,7 +3,7 @@ net461 latest - 2.0.0 + 0.0.0 @@ -16,7 +16,7 @@ Feli openmod openmod-plugin unturned - 2.0.0 + 0.0.0 true true