diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml new file mode 100644 index 0000000..5962658 --- /dev/null +++ b/.github/workflows/publish.yml @@ -0,0 +1,15 @@ +name: Deployment +on: + release: + types: [created] +jobs: + deploy: + name: Deployment + runs-on: windows-2019 + steps: + - uses: actions/checkout@v2 + - name: Push + env: + NUGET_KEY: ${{ secrets.NUGET_KEY }} + run: | + ./publish.ps1 -GalleryApiKey $env:NUGET_KEY diff --git a/publish.ps1 b/publish.ps1 index 7d31dad..fb1ef7a 100644 --- a/publish.ps1 +++ b/publish.ps1 @@ -5,5 +5,5 @@ param( ) [Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12 -$env:PSModulePath = $env:PSModulePath + [System.IO.Path]::PathSeparator + "$(pwd)" +$env:PSModulePath = $env:PSModulePath + [System.IO.Path]::PathSeparator + "$(Get-Location)" Publish-Module -Name PsUWI -NuGetApiKey $GalleryApiKey \ No newline at end of file