Skip to content

Commit d35f1ea

Browse files
Merge pull request #3775 from continuedev/pe/workflow-dispatch-jb
Update jetbrains-release.yaml
2 parents a74d322 + 85c664e commit d35f1ea

File tree

1 file changed

+13
-5
lines changed

1 file changed

+13
-5
lines changed

.github/workflows/jetbrains-release.yaml

Lines changed: 13 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,13 @@ name: JetBrains Release
66

77
on:
88
release:
9-
types: [prereleased]
9+
types: [ prereleased ]
10+
workflow_dispatch:
11+
inputs:
12+
publish_build:
13+
description: `Whether or not to publish the built extension to the JetBrains marketplace`
14+
required: true
15+
default: false
1016

1117
defaults:
1218
run:
@@ -34,7 +40,7 @@ jobs:
3440
# Prepare and publish the plugin to JetBrains Marketplace repository
3541
build:
3642
needs: check_release_name
37-
if: needs.check_release_name.outputs.should_run == 'true'
43+
if: needs.check_release_name.outputs.should_run == 'true' || github.event_name == 'workflow_dispatch'
3844
name: Build Plugin
3945
runs-on: macos-latest
4046
permissions:
@@ -175,6 +181,7 @@ jobs:
175181

176182
# Publish the plugin to JetBrains Marketplace
177183
- name: Publish EAP Plugin
184+
if: github.event_name == 'release' || github.event.inputs.publish_build == 'true'
178185
env:
179186
PUBLISH_TOKEN: ${{ secrets.JETBRAINS_PUBLISH_TOKEN }}
180187
CERTIFICATE_CHAIN: ${{ secrets.JETBRAINS_CERTIFICATE_CHAIN }}
@@ -184,6 +191,7 @@ jobs:
184191
run: ./gradlew publishPlugin
185192

186193
- name: Publish Stable Plugin
194+
if: github.event_name == 'release' || github.event.inputs.publish_build == 'true'
187195
env:
188196
PUBLISH_TOKEN: ${{ secrets.JETBRAINS_PUBLISH_TOKEN }}
189197
CERTIFICATE_CHAIN: ${{ secrets.JETBRAINS_CERTIFICATE_CHAIN }}
@@ -337,7 +345,7 @@ jobs:
337345
# Run tests and upload a code coverage report
338346
test:
339347
name: Test
340-
needs: [build]
348+
needs: [ build ]
341349
runs-on: ubuntu-latest
342350
steps:
343351
# Check out current repository
@@ -379,7 +387,7 @@ jobs:
379387
inspectCode:
380388
if: false
381389
name: Inspect code
382-
needs: [build]
390+
needs: [ build ]
383391
runs-on: ubuntu-latest
384392
permissions:
385393
contents: write
@@ -414,7 +422,7 @@ jobs:
414422
verify:
415423
if: false
416424
name: Verify plugin
417-
needs: [build]
425+
needs: [ build ]
418426
runs-on: ubuntu-latest
419427
steps:
420428
# Free GitHub Actions Environment Disk Space

0 commit comments

Comments
 (0)