Skip to content

Commit

Permalink
Chore/allow single packages updated and add prefect-ui-library (#10)
Browse files Browse the repository at this point in the history
* Separate out release paths

* Update prefect ui library

* Add secret
  • Loading branch information
jimid27 authored Mar 14, 2024
1 parent d5d6108 commit fd4282e
Showing 1 changed file with 28 additions and 4 deletions.
32 changes: 28 additions & 4 deletions action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,21 @@ inputs:
PREFECT_OSS_ACTIONS_RW_TOKEN:
description: The Github token to use for triggering the Prefect OSS NPM package update.
required: false
UPDATE_DOWNSTREAM_REPOS:
description: Whether to trigger the Nebula UI and Prefect OSS NPM package updates.
PREFECT_UI_LIBRARY_ACTIONS_RW_TOKEN:
description: The Github token to use for triggering the Prefect UI Library NPM package update.
required: false
UPDATE_DOWNSTREAM_NEBULA_UI_REPO:
description: Whether to trigger Nebula UI NPM package updates.
required: false
default: "true"
UPDATE_DOWNSTREAM_OSS_REPO:
description: Whether to trigger Prefect OSS NPM package updates.
required: false
default: "true"
UPDATE_DOWNSTREAM_PREFECT_UI_LIBRARY_REPO:
description: Whether to trigger Prefect UI Library NPM package updates.
required: false
default: "false"
runs:
using: composite
steps:
Expand Down Expand Up @@ -60,7 +71,7 @@ runs:
GITHUB_TOKEN: ${{ inputs.NEBULA_UI_ACTIONS_RW_TOKEN }}
tag: ${{ steps.publish.outputs.version }}
run: |
if ${{ inputs.UPDATE_DOWNSTREAM_REPOS == 'true' }} && ${{ steps.publish.outputs.type }}; then
if ${{ inputs.UPDATE_DOWNSTREAM_NEBULA_UI_REPO == 'true' }} && ${{ steps.publish.outputs.type }}; then
gh workflow run npm_update_latest_prefect.yaml \
--repo=prefecthq/nebula-ui \
--ref=main \
Expand All @@ -74,11 +85,24 @@ runs:
GITHUB_TOKEN: ${{ inputs.PREFECT_OSS_ACTIONS_RW_TOKEN }}
tag: ${{ steps.publish.outputs.version }}
run: |
if ${{ inputs.UPDATE_DOWNSTREAM_REPOS == 'true' }} && ${{ steps.publish.outputs.type }}; then
if ${{ inputs.UPDATE_DOWNSTREAM_OSS_REPO == 'true' }} && ${{ steps.publish.outputs.type }}; then
gh workflow run npm_update_latest_prefect.yaml \
--repo=prefecthq/prefect \
--ref=main \
-f package_name="$(echo $GITHUB_REPOSITORY | tr '[:upper:]' '[:lower:]')" \
-f package_version="$tag"
fi
shell: bash
- name: Trigger Prefect OSS NPM Package Update
env:
GITHUB_TOKEN: ${{ inputs.PREFECT_UI_LIBRARY_ACTIONS_RW_TOKEN }}
tag: ${{ steps.publish.outputs.version }}
run: |
if ${{ inputs.UPDATE_DOWNSTREAM_PREFECT_UI_LIBRARY_REPO == 'true' }} && ${{ steps.publish.outputs.type }}; then
gh workflow run npm_update_latest_prefect.yaml \
--repo=prefecthq/prefect-ui-library \
--ref=main \
-f package_name="$(echo $GITHUB_REPOSITORY | tr '[:upper:]' '[:lower:]')" \
-f package_version="$tag"
fi
shell: bash

0 comments on commit fd4282e

Please sign in to comment.