File tree Expand file tree Collapse file tree 1 file changed +8
-10
lines changed Expand file tree Collapse file tree 1 file changed +8
-10
lines changed Original file line number Diff line number Diff line change 11#! /bin/bash
2+ set -euo pipefail
23
34ret_code=0
45
56install_dependencies (){
6- if [ " $RUNNER_OS " == " Linux" ]; then
7+ if [[ " $RUNNER_OS " == " Linux" ] ]; then
78 # https://github.com/pypa/setuptools/issues/3269
89 export DEB_PYTHON_INSTALL_LAYOUT=deb
910 fi
@@ -12,16 +13,13 @@ install_dependencies(){
1213
1314run_commit_check (){
1415 args=" "
15- if [ " $MESSAGE " == " true" ]; then
16+ if [[ " $MESSAGE " == " true" ] ]; then
1617 args=" $args --message"
17- fi
18- if [ " $BRANCH " == " true" ]; then
18+ elif [[ " $BRANCH " == " true" ]]; then
1919 args=" $args --branch"
20- fi
21- if [ " $AUTHOR_NAME " == " true" ]; then
20+ elif [[ " $AUTHOR_NAME " == " true" ]]; then
2221 args=" $args --author-name"
23- fi
24- if [ " $AUTHOR_EMAIL " == " true" ]; then
22+ elif [[ " $AUTHOR_EMAIL " == " true" ]]; then
2523 args=" $args --author-email"
2624 fi
2725
@@ -31,7 +29,7 @@ run_commit_check(){
3129}
3230
3331add_job_summary (){
34- if [ " $JOB_SUMMARY " == " false" ]; then
32+ if [[ " $JOB_SUMMARY " == " false" ] ]; then
3533 exit
3634 fi
3735
@@ -54,7 +52,7 @@ install_dependencies
5452run_commit_check
5553add_job_summary
5654
57- if [ " $DRY_RUN " == " true" ]; then
55+ if [[ " $DRY_RUN " == " true" ] ]; then
5856 ret_code=0
5957fi
6058
You can’t perform that action at this time.
0 commit comments