File tree Expand file tree Collapse file tree 5 files changed +164
-158
lines changed Expand file tree Collapse file tree 5 files changed +164
-158
lines changed Original file line number Diff line number Diff line change 17
17
- name : Run ShellCheck
18
18
uses : ludeeus/action-shellcheck@master
19
19
with :
20
- scandir : " ./src "
20
+ scandir : " ."
21
21
22
22
readme :
23
23
runs-on : ubuntu-latest
Original file line number Diff line number Diff line change 14
14
# See the License for the specific language governing permissions and
15
15
# limitations under the License.
16
16
17
- set -e
17
+ set -o errexit
18
+ set -o pipefail
19
+ set -o errtrace
18
20
19
21
NEW_VERSION=$1
20
22
PWD=$( cd " $( dirname " $0 " ) " && pwd -P)
21
23
22
24
if [ -z " ${NEW_VERSION} " ]; then
23
- echo " Must have version like: v1.0.1"
24
- exit 1
25
+ echo " Must have version like: v1.0.1"
26
+ exit 1
25
27
fi
26
28
27
29
CURRENT_BRANCH=$( git rev-parse --abbrev-ref HEAD)
28
30
29
- if [[ " ${CURRENT_BRANCH} " == " main" ] ]; then
30
- git pull origin main
31
- git checkout -b " release/${NEW_VERSION} "
32
- elif [[ " ${CURRENT_BRANCH} " == " release/${NEW_VERSION} " ] ]; then
33
- git pull origin main
31
+ if [ " ${CURRENT_BRANCH} " = " main" ]; then
32
+ git pull origin main
33
+ git checkout -b " release/${NEW_VERSION} "
34
+ elif [ " ${CURRENT_BRANCH} " = " release/${NEW_VERSION} " ]; then
35
+ git pull origin main
34
36
else
35
- echo " Invalid branch"
36
- exit 1
37
+ echo " Invalid branch"
38
+ exit 1
37
39
fi
38
40
39
41
# Update README
Original file line number Diff line number Diff line change 14
14
# See the License for the specific language governing permissions and
15
15
# limitations under the License.
16
16
17
- set -e
17
+ set -o errexit
18
+ set -o pipefail
19
+ set -o errtrace
18
20
19
21
CURRENT_BRANCH=$( git rev-parse --abbrev-ref HEAD)
20
22
21
23
if [[ " ${CURRENT_BRANCH} " != " main" ]]; then
22
- echo " Must be on main branch"
23
- exit 1
24
+ echo " Must be on main branch"
25
+ exit 1
24
26
fi
25
27
26
28
NEW_VERSION=$1
27
29
28
30
if [ -z " ${NEW_VERSION} " ]; then
29
- echo " Must have version like: v1.0.1"
30
- exit 1
31
+ echo " Must have version like: v1.0.1"
32
+ exit 1
31
33
fi
32
34
33
35
git pull origin main
Original file line number Diff line number Diff line change 14
14
# See the License for the specific language governing permissions and
15
15
# limitations under the License.
16
16
17
- set -e
17
+ set -o errexit
18
+ set -o pipefail
19
+ set -o errtrace
18
20
19
21
NEW_VERSION=$1
20
22
@@ -25,11 +27,11 @@ if [ -z "${NEW_VERSION}" ]; then
25
27
fi
26
28
27
29
if [ -z " ${NEW_VERSION} " ]; then
28
- echo " Must have version like: v1.0.1"
29
- exit 1
30
+ echo " Must have version like: v1.0.1"
31
+ exit 1
30
32
fi
31
33
32
34
# Update the README
33
35
VERSION=${NEW_VERSION} gomplate -d action=" ${PWD} " /../action.yml -f " ${PWD} " /../.github/templates/README.tpl -o " ${PWD} " /../README.md
34
36
35
- echo " README.md updated."
37
+ echo " README.md updated."
You can’t perform that action at this time.
0 commit comments