Skip to content

Manual: build raycast_extensions/extensions/1-click-confetti #12

Manual: build raycast_extensions/extensions/1-click-confetti

Manual: build raycast_extensions/extensions/1-click-confetti #12

name: Extensions
run-name: "${{ github.event_name == 'push' && format('Publish: {0}', github.event.head_commit.message) || (github.event_name == 'pull_request' && format('Check: {0}', github.event.pull_request.title) || github.event_name == 'workflow_dispatch' && format('Manual: {0} {1}', inputs.command, inputs.paths) || format('Event: {0}', github.event_name) ) }}"
on:
workflow_dispatch:
inputs:
paths:
description: 'Extensions to update (comma-separated relative paths for extensions) or ("extensions/**"" to execute on all possible subdirectories)'
default: 'raycast_extensions/extensions/**'
required: true
command:
description: "Ray CLI command to run (build | publish)"
default: "build"
required: true
# cli_version:
# description: 'CLI Version (optional, eg. "1.0.0")'
# required: false
pull_request:
paths:
- "extensions/**"
branches: [main, master]
push:
paths:
- "extensions/**"
branches: [main, master]
jobs:
extensions_build_publish:
if: github.repository == 'BlastLauncher/raycast-extensions-mirror'
name: "${{ github.event_name == 'push' && 'Publish' || (github.event_name == 'pull_request' && 'Check' || github.event_name == 'workflow_dispatch' && inputs.command || github.event_name ) }}"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
submodules: true
# - name: Checkout
# uses: raycast/github-actions/git-checkout@v1.13.0
# This makes sure that the problems found while validating the extensions are shown in the PR diff
# - name: Register Problem Matcher for Ray CLI
# run: echo "##[add-matcher].github/ray.matcher.json"
# - name: Generate 'allow_owners_only_for_extensions'
# id: allow_owners_only_for_extensions
# run: |
# file_path="${{ github.workspace }}/.github/public_raycast_extensions.txt"
# if [[ -f "$file_path" ]]; then
# echo "value<<EOF" >> $GITHUB_OUTPUT
# cat "$file_path"; echo >> $GITHUB_OUTPUT
# echo 'EOF' >> $GITHUB_OUTPUT
# fi
- name: Run Blast CLI
id: blast_cli
uses: BlastLauncher/actions/blast-cli@main
with:
npm_token: "${{ secrets.NPM_TOKEN }}"
command: "${{ github.event.inputs.command }}"
paths: "${{ github.event.inputs.paths }}"
# cli_version: "${{ github.event.inputs.cli_version }}"
allow_owners_only_for_extensions: "${{ steps.allow_owners_only_for_extensions.outputs.value }}"
# - name: Run Ray CLI
# id: ray_cli
# uses: raycast/github-actions/ray@v1.13.0
# with:
# access_token: "${{ secrets.RAYCAST_CLI_ACCESS_TOKEN }}"
# command: "${{ github.event.inputs.command }}"
# paths: "${{ github.event.inputs.paths }}"
# cli_version: "${{ github.event.inputs.cli_version }}"
# allow_owners_only_for_extensions: "${{ steps.allow_owners_only_for_extensions.outputs.value }}"
# - name: Post Store URLs
# uses: raycast/github-actions/git-post-store-urls-to-pr@v1.13.0
# with:
# store_urls: ${{ steps.ray_cli.outputs.store_urls }}
# github_token: ${{ secrets.PERSONAL_ACCESS_TOKEN }}
# - name: Notify Failure to Slack
# if: failure() && (github.event_name == 'push' || github.event_name == 'workflow_dispatch')
# uses: raycast/github-actions/slack-send@master
# with:
# webhook: ${{ github.event_name == 'workflow_dispatch' && secrets.SLACK_RELEASE_CHANNEL_WEBHOOK_URL || secrets.SLACK_STREAM_ERRORS_STORE_PUBLIC }}
# color: "danger"
# text: |
# :no_entry_sign: ${env.GITHUB_WORKFLOW} has failed
# <${env.GITHUB_SERVER_URL}/${env.GITHUB_REPOSITORY}/actions/runs/${env.GITHUB_RUN_ID}|Action logs> | <${env.GITHUB_SERVER_URL}/${env.GITHUB_REPOSITORY}/commit/${ env.GITHUB_SHA }|Commit: ${ env.GITHUB_SHA.substr(0,8) }>
# - name: Notify Success to Slack
# if: success() && github.event_name == 'workflow_dispatch'
# uses: raycast/github-actions/slack-send@master
# with:
# webhook: ${{ secrets.SLACK_RELEASE_CHANNEL_WEBHOOK_URL }}
# color: "good"
# text: |
# :white_check_mark: ${env.GITHUB_WORKFLOW} has succeeded
# <${env.GITHUB_SERVER_URL}/${env.GITHUB_REPOSITORY}/actions/runs/${env.GITHUB_RUN_ID}|Action logs> | <${env.GITHUB_SERVER_URL}/${env.GITHUB_REPOSITORY}/commit/${ env.GITHUB_SHA }|Commit: ${ env.GITHUB_SHA.substr(0,8) }>