@@ -10,6 +10,9 @@ inputs:
1010 project-name :
1111 description : ' The Project Name (e.g. RICADO.Logging)'
1212 required : true
13+ github-token :
14+ description : ' The GitHub Token used to Generate a Changelog and Create Releases'
15+ required : true
1316 private-nuget-url :
1417 description : ' The URL of the Private NuGet Repository (e.g. https://nuget.pkg.github.com/myname/index.json)'
1518 required : true
@@ -53,41 +56,46 @@ runs:
5356 # Step 3 - Restore NuGet Packages
5457 - name : Restore NuGet Packages
5558 run : dotnet restore "${{ inputs.project-name }}/${{ inputs.project-name }}.csproj"
59+ shell : bash
5660
5761 # Step 4 - Build the Library
5862 - name : Build the Library
5963 run : dotnet build "${{ inputs.project-name }}/${{ inputs.project-name }}.csproj" -c Release --no-restore
64+ shell : bash
6065
6166 # Step 5 - Pack the Library
6267 - name : Pack the Library
6368 if : ${{ startsWith(github.ref, 'refs/tags/') }}
6469 run : dotnet pack "${{ inputs.project-name}}/${{ inputs.project-name }}.csproj" -c Release -p:PackageVersion=${{ env.CI_REF_NAME }}
70+ shell : bash
6571
6672 # Step 6 - Push the Package to GitHub Packages
6773 - name : Push the Package to GitHub Packages
6874 if : ${{ startsWith(github.ref, 'refs/tags/') }}
6975 run : dotnet nuget push "${{ inputs.project-name }}/bin/Release/*.nupkg" -k ${{ inputs.private-nuget-token }} -s "${{ inputs.private-nuget-url }}" --skip-duplicate
76+ shell : bash
7077
7178 # Step 7 - Push the Package to NuGet
7279 - name : Push the Package to Nuget
7380 if : ${{ startsWith(github.ref, 'refs/tags/') && inputs.publish-public == 'true' }}
7481 run : dotnet nuget push "${{ inputs.project-name }}/bin/Release/*.nupkg" -k ${{ inputs.public-nuget-token }} -s "${{ inputs.public-nuget-url }}" --skip-duplicate
82+ shell : bash
7583
7684 # Step 8 - Generate the Changelog
7785 - name : Generate the Changelog
7886 id : changelog
7987 if : ${{ startsWith(github.ref, 'refs/tags/') }}
8088 uses : metcalfc/changelog-generator@v3.0.0
8189 with :
82- myToken : ${{ secrets.GITHUB_TOKEN }}
90+ myToken : ${{ inputs.github-token }}
8391
8492 # Step 9 - Create New Release
8593 - name : Create New Release
8694 id : create-release
8795 if : ${{ startsWith(github.ref, 'refs/tags/') }}
8896 uses : softprops/action-gh-release@v1
8997 env :
90- GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
98+ GITHUB_TOKEN : ${{ inputs.github-token }}
9199 with :
92100 tag_name : ${{ env.CI_REF_NAME }}
93101 name : Version ${{ env.CI_REF_NAME }}
0 commit comments