Skip to content

Commit c7d48e9

Browse files
authored
Allow customizing the shell for the action (#549)
1 parent 123d7a7 commit c7d48e9

File tree

5 files changed

+37
-17
lines changed

5 files changed

+37
-17
lines changed

.github/actions/check-release/action.yml

+8-4
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,14 @@ inputs:
1111
steps_to_skip:
1212
description: "Comma separated list of steps to skip"
1313
required: false
14+
shell:
15+
description: "The shell being used for the action steps"
16+
required: false
17+
default: bash -eux {0}
1418
runs:
1519
using: "composite"
1620
steps:
17-
- shell: bash -eux {0}
21+
- shell: ${{ inputs.shell }}
1822
id: install-releaser
1923
run: |
2024
# Install Jupyter Releaser from git unless we are testing Releaser itself
@@ -24,7 +28,7 @@ runs:
2428
fi
2529
2630
- id: prep-release
27-
shell: bash -eux {0}
31+
shell: ${{ inputs.shell }}
2832
run: |
2933
export RH_DRY_RUN="true"
3034
export GITHUB_ACCESS_TOKEN=${{ inputs.token }}
@@ -33,7 +37,7 @@ runs:
3337
python -m jupyter_releaser.actions.prep_release
3438
3539
- id: populate-release
36-
shell: bash -eux {0}
40+
shell: ${{ inputs.shell }}
3741
run: |
3842
export RH_DRY_RUN="true"
3943
export GITHUB_ACCESS_TOKEN=${{ inputs.token }}
@@ -43,7 +47,7 @@ runs:
4347
python -m jupyter_releaser.actions.populate_release
4448
4549
- id: finalize-release
46-
shell: bash -eux {0}
50+
shell: ${{ inputs.shell }}
4751
run: |
4852
export RH_DRY_RUN="true"
4953
export GITHUB_ACCESS_TOKEN=${{ inputs.token }}

.github/actions/finalize-release/action.yml

+8-4
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,10 @@ inputs:
2020
steps_to_skip:
2121
description: "Comma separated list of steps to skip"
2222
required: false
23+
shell:
24+
description: "The shell being used for the action steps"
25+
required: false
26+
default: bash -eux {0}
2327

2428
outputs:
2529
release_url:
@@ -33,7 +37,7 @@ runs:
3337
using: "composite"
3438
steps:
3539
- name: install-releaser
36-
shell: bash -eux {0}
40+
shell: ${{ inputs.shell }}
3741
run: |
3842
# Install Jupyter Releaser from git unless we are testing Releaser itself
3943
if ! command -v jupyter-releaser &> /dev/null
@@ -42,7 +46,7 @@ runs:
4246
fi
4347
4448
- id: finalize-release
45-
shell: bash -eux {0}
49+
shell: ${{ inputs.shell }}
4650
run: |
4751
export GITHUB_ACCESS_TOKEN=${{ inputs.token }}
4852
export GITHUB_ACTOR=${{ github.triggering_actor }}
@@ -54,7 +58,7 @@ runs:
5458
python -m jupyter_releaser.actions.finalize_release
5559
5660
- if: ${{ success() }}
57-
shell: bash -eux {0}
61+
shell: ${{ inputs.shell }}
5862
run: |
5963
echo "## Next Step" >> $GITHUB_STEP_SUMMARY
6064
echo "Verify the final release" >> $GITHUB_STEP_SUMMARY
@@ -67,7 +71,7 @@ runs:
6771
fi
6872
6973
- if: ${{ failure() }}
70-
shell: bash -eux {0}
74+
shell: ${{ inputs.shell }}
7175
run: |
7276
echo "## Failure Message" >> $GITHUB_STEP_SUMMARY
7377
echo ":x: Failed to Publish the Draft Release Url:" >> $GITHUB_STEP_SUMMARY

.github/actions/populate-release/action.yml

+7-3
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,10 @@ inputs:
2020
steps_to_skip:
2121
description: "Comma separated list of steps to skip"
2222
required: false
23+
shell:
24+
description: "The shell being used for the action steps"
25+
required: false
26+
default: bash -eux {0}
2327

2428
outputs:
2529
release_url:
@@ -30,7 +34,7 @@ runs:
3034
using: "composite"
3135
steps:
3236
- name: install-releaser
33-
shell: bash -eux {0}
37+
shell: ${{ inputs.shell }}
3438
run: |
3539
# Install Jupyter Releaser from git unless we are testing Releaser itself
3640
if ! command -v jupyter-releaser &> /dev/null
@@ -39,7 +43,7 @@ runs:
3943
fi
4044
4145
- id: populate-release
42-
shell: bash -eux {0}
46+
shell: ${{ inputs.shell }}
4347
run: |
4448
export GITHUB_ACCESS_TOKEN=${{ inputs.token }}
4549
export GITHUB_ACTOR=${{ github.triggering_actor }}
@@ -51,7 +55,7 @@ runs:
5155
python -m jupyter_releaser.actions.populate_release
5256
5357
- if: ${{ failure() }}
54-
shell: bash -eux {0}
58+
shell: ${{ inputs.shell }}
5559
run: |
5660
echo "## Failure Message" >> $GITHUB_STEP_SUMMARY
5761
echo ":x: Failed to Publish the Draft Release Url:" >> $GITHUB_STEP_SUMMARY

.github/actions/prep-release/action.yml

+7-3
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,10 @@ inputs:
3131
since_last_stable:
3232
description: "Use PRs with activity since the last stable git tag"
3333
required: false
34+
shell:
35+
description: "The shell being used for the action steps"
36+
required: false
37+
default: bash -eux {0}
3438
outputs:
3539
release_url:
3640
description: "The html URL of the draft GitHub release"
@@ -39,7 +43,7 @@ runs:
3943
using: "composite"
4044
steps:
4145
- name: install-releaser
42-
shell: bash -eux {0}
46+
shell: ${{ inputs.shell }}
4347
run: |
4448
# Install Jupyter Releaser from git unless we are testing Releaser itself
4549
if ! command -v jupyter-releaser &> /dev/null
@@ -48,7 +52,7 @@ runs:
4852
fi
4953
5054
- id: prep-release
51-
shell: bash -eux {0}
55+
shell: ${{ inputs.shell }}
5256
run: |
5357
export GITHUB_ACCESS_TOKEN=${{ inputs.token }}
5458
export GITHUB_ACTOR=${{ github.triggering_actor }}
@@ -65,7 +69,7 @@ runs:
6569
6670
python -m jupyter_releaser.actions.prep_release
6771
68-
- shell: bash -eux {0}
72+
- shell: ${{ inputs.shell }}
6973
run: |
7074
echo "## Next Step" >> $GITHUB_STEP_SUMMARY
7175
echo "(Optional): Review Draft Release: ${{ steps.prep-release.outputs.release_url }}" >> $GITHUB_STEP_SUMMARY

.github/actions/publish-changelog/action.yml

+7-3
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,10 @@ inputs:
1414
description: "If set, do not make a PR"
1515
default: "false"
1616
required: false
17+
shell:
18+
description: "The shell being used for the action steps"
19+
required: false
20+
default: bash -eux {0}
1721
outputs:
1822
pr_url:
1923
description: "The html URL of the draft GitHub release"
@@ -22,7 +26,7 @@ runs:
2226
using: "composite"
2327
steps:
2428
- name: install-releaser
25-
shell: bash -eux {0}
29+
shell: ${{ inputs.shell }}
2630
run: |
2731
# Install Jupyter Releaser from git unless we are testing Releaser itself
2832
if ! command -v jupyter-releaser &> /dev/null
@@ -31,7 +35,7 @@ runs:
3135
fi
3236
3337
- id: publish-changelog
34-
shell: bash -eux {0}
38+
shell: ${{ inputs.shell }}
3539
run: |
3640
export GITHUB_ACCESS_TOKEN=${{ inputs.token }}
3741
export GITHUB_ACTOR=${{ github.triggering_actor }}
@@ -43,7 +47,7 @@ runs:
4347
4448
python -m jupyter_releaser.actions.publish_changelog
4549
46-
- shell: bash -eux {0}
50+
- shell: ${{ inputs.shell }}
4751
run: |
4852
echo "## Next Step" >> $GITHUB_STEP_SUMMARY
4953
echo "Merge the changelog update PR: ${{ steps.publish-changelog.outputs.pr_url }}" >> $GITHUB_STEP_SUMMARY

0 commit comments

Comments
 (0)