File tree Expand file tree Collapse file tree 1 file changed +8
-4
lines changed Expand file tree Collapse file tree 1 file changed +8
-4
lines changed Original file line number Diff line number Diff line change @@ -180,12 +180,16 @@ if [[ "$stable" == 1 ]]; then
180
180
fi
181
181
182
182
target_commitish=main # This is the default.
183
- release_branch_refname=$( git branch --remotes --contains " ${new_tag} " --format ' %(refname)' ' */release/*' )
184
- if [[ -n " ${release_branch_refname} " ]]; then
185
- # refs/remotes/origin/release/2.9 -> release/2.9
186
- target_commitish=" release/${release_branch_refname#* release/ } "
183
+ # Skip during dry-runs
184
+ if [[ " $dry_run " == 0 ]]; then
185
+ release_branch_refname=$( git branch --remotes --contains " ${new_tag} " --format ' %(refname)' ' */release/*' )
186
+ if [[ -n " ${release_branch_refname} " ]]; then
187
+ # refs/remotes/origin/release/2.9 -> release/2.9
188
+ target_commitish=" release/${release_branch_refname#* release/ } "
189
+ fi
187
190
fi
188
191
192
+
189
193
# We pipe `true` into `gh` so that it never tries to be interactive.
190
194
true |
191
195
maybedryrun " $dry_run " gh release create \
You can’t perform that action at this time.
0 commit comments