Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

prs_created is false when a release PR is updated #963

Open
airtonix opened this issue Mar 26, 2024 · 0 comments
Open

prs_created is false when a release PR is updated #963

airtonix opened this issue Mar 26, 2024 · 0 comments

Comments

@airtonix
Copy link
Contributor

TL;DR

image

says it will set prs_created to true when it updates a pr.

but it doesn't.

Expected behavior

if a release pr is updated, set prs_created to true.

Observed behavior

if a release pr is updated, set prs_created to false.

Action YAML

name: Release

on:
  push:
    branches:
      - master

env:
  HUSKY: 0 # https://typicode.github.io/husky/how-to.html#ci-server-and-docker

concurrency:
  group: ${{ github.workflow }}-${{ github.ref }}

# Needed for nx-set-shas within nx-cloud-main.yml, when run on the master branch
permissions:
  actions: read
  contents: write
  deployments: write
  pull-requests: write
  id-token: write

jobs:
  Process:
    runs-on: ubuntu-latest
    outputs:
      releases_created: ${{ steps.release-please.outputs.releases_created }}
    steps:
      - uses: google-github-actions/release-please-action@v4
        id: release-please
        with:
          token: ${{secrets.MY_MAGICAL_TOKEN}}
      - name: Print Release Data
        run: |
          echo 'Release Data:'

          echo '''
            ${{ toJSON(steps.release-please.outputs) }}
          '''

  Deploy:
    needs: Process
    runs-on: ubuntu-latest
    steps:
      - name: Checkout
        uses: actions/checkout@v3
        with:
          fetch-depth: 0

      - uses: asdf-vm/actions/install@f4acd427436df623426c29f7e3e9ea715be28396

      - name: Yarn
        uses: ./.github/actions/setup-yarn

      - name: Configure Publishing
        uses: ./.github/actions/setup-npm-publish
        with:
          NpmRegistryUrl: https://registry.npmjs.org/
          NpmRcFile: .npmrc

      - uses: nrwl/nx-set-shas@v3

      - uses: mansagroup/nrwl-nx-action@v3.2.2
        if: ${{ needs.Process.outputs.releases_created == 'true' && needs.Process.outputs.prs_created != 'true' }}
        with:
          targets: release
          args: '--configuration=production'

      - uses: mansagroup/nrwl-nx-action@v3.2.2
        if: ${{ needs.Process.outputs.releases_created != 'true' && needs.Process.outputs.prs_created == 'true' }}
        with:
          targets: release
          args: '--configuration=development'

Log output

Run echo 'Release Data:'
Release Data:

  {
  "releases_created": "false",
  "paths_released": "[]",
  "prs_created": "false"
}


### Additional information

_No response_
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant