title: Only run GitHub Actions step if not a pull request
body: <p>I have a workflow which needs to execute either on a push or a pull request with the exception of the last step which pushes a package to NuGet (I don't want this to occur on a pull request, even to master).</p>
  <p>How can I prevent the Publish NuGet step from running if the workflow is triggered from a pull request?</p>
  <pre class="lang-yaml prettyprint-override"><code>name: .NET Core
  
  on:
    push:
      branches: [ master ]
    pull_request:
      branches: [ master ]
  
  jobs:
    build:
  
      runs-on: ubuntu-latest
  
      steps:
      - uses: actions/checkout@v2
      - name: Setup .NET Core
        uses: actions/setup-dotnet@v1
        with:
          dotnet-version: 3.1.101
      - name: Install dependencies
        run: dotnet restore
      - name: Build
        run: dotnet build --configuration Release --no-restore
      - name: Test
        run: dotnet test --no-restore --verbosity normal
      - name: Publish NuGet
        uses: brandedoutcast/publish-nuget@v2.5.2
        with:
          PROJECT_FILE_PATH: &quot;Orleans.Sagas/Orleans.Sagas.csproj&quot;
          NUGET_KEY: ${{secrets.NUGET_KEY}}
  </code></pre>