From 183ae196ba3423f4801fc7cac5d48fae62c969c1 Mon Sep 17 00:00:00 2001 From: Peter Shen Date: Fri, 14 Apr 2023 08:25:09 -0600 Subject: [PATCH 1/5] refactor: Update entrypoint.sh (#20) --- entrypoint.sh | 18 ++++++++---------- 1 file changed, 8 insertions(+), 10 deletions(-) diff --git a/entrypoint.sh b/entrypoint.sh index 98703ea..3e365c7 100755 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -1,9 +1,10 @@ #!/bin/bash +set -euo pipefail ret_code=0 install_dependencies(){ - if [ "$RUNNER_OS" == "Linux" ]; then + if [[ "$RUNNER_OS" == "Linux" ]]; then # https://github.com/pypa/setuptools/issues/3269 export DEB_PYTHON_INSTALL_LAYOUT=deb fi @@ -12,16 +13,13 @@ install_dependencies(){ run_commit_check(){ args="" - if [ "$MESSAGE" == "true" ]; then + if [[ "$MESSAGE" == "true" ]]; then args="$args --message" - fi - if [ "$BRANCH" == "true" ]; then + elif [[ "$BRANCH" == "true" ]]; then args="$args --branch" - fi - if [ "$AUTHOR_NAME" == "true" ]; then + elif [[ "$AUTHOR_NAME" == "true" ]]; then args="$args --author-name" - fi - if [ "$AUTHOR_EMAIL" == "true" ]; then + elif [[ "$AUTHOR_EMAIL" == "true" ]]; then args="$args --author-email" fi @@ -31,7 +29,7 @@ run_commit_check(){ } add_job_summary(){ - if [ "$JOB_SUMMARY" == "false" ]; then + if [[ "$JOB_SUMMARY" == "false" ]]; then exit fi @@ -54,7 +52,7 @@ install_dependencies run_commit_check add_job_summary -if [ "$DRY_RUN" == "true" ]; then +if [[ "$DRY_RUN" == "true" ]]; then ret_code=0 fi From b18b48afc821b905890f1e006c6e096df7048f18 Mon Sep 17 00:00:00 2001 From: Peter Shen Date: Wed, 19 Apr 2023 12:15:06 +0800 Subject: [PATCH 2/5] feat: create CODEOWNERS file --- .github/CODEOWNERS | 1 + 1 file changed, 1 insertion(+) create mode 100644 .github/CODEOWNERS diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS new file mode 100644 index 0000000..4f08a45 --- /dev/null +++ b/.github/CODEOWNERS @@ -0,0 +1 @@ +* @shenxianpeng From 3d602860a8e08c39800a80ea59e1470473c8dd3c Mon Sep 17 00:00:00 2001 From: Peter Shen Date: Thu, 4 May 2023 11:57:56 +0800 Subject: [PATCH 3/5] chore: Update README.md --- README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.md b/README.md index c51c662..3512e9c 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,7 @@ # Commit-Check GitHub Action +[![Main](https://github.com/commit-check/commit-check-action/actions/workflows/main.yaml/badge.svg)](https://github.com/commit-check/commit-check-action/actions/workflows/main.yaml) +[![Commit Check](https://github.com/commit-check/commit-check-action/actions/workflows/commit-check.yml/badge.svg)](https://github.com/commit-check/commit-check-action/actions/workflows/commit-check.yml) ![GitHub release (latest SemVer)](https://img.shields.io/github/v/release/commit-check/commit-check-action) [![GitHub marketplace](https://img.shields.io/badge/Marketplace-commit--check--action-blue)](https://github.com/marketplace/actions/commit-check-action) From e8c0354cb5b4da1dc1f062e38999a320891c6235 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 4 Sep 2023 23:20:25 -0400 Subject: [PATCH 4/5] chore(deps): bump actions/checkout from 3 to 4 (#21) Bumps [actions/checkout](https://github.com/actions/checkout) from 3 to 4. - [Release notes](https://github.com/actions/checkout/releases) - [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md) - [Commits](https://github.com/actions/checkout/compare/v3...v4) --- updated-dependencies: - dependency-name: actions/checkout dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- .github/workflows/commit-check.yml | 2 +- .github/workflows/main.yaml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/commit-check.yml b/.github/workflows/commit-check.yml index 700425f..bb45d9e 100644 --- a/.github/workflows/commit-check.yml +++ b/.github/workflows/commit-check.yml @@ -10,7 +10,7 @@ jobs: commit-check: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - uses: commit-check/commit-check-action@v1 with: message: true diff --git a/.github/workflows/main.yaml b/.github/workflows/main.yaml index 3076451..913593d 100644 --- a/.github/workflows/main.yaml +++ b/.github/workflows/main.yaml @@ -19,7 +19,7 @@ jobs: re-tag: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 with: fetch-depth: 0 ref: ${{ inputs.ref }} From a8a4d8a4e5fa8fc276db91abafcf168f4f2b90a5 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 3 Nov 2023 09:50:42 +0800 Subject: [PATCH 5/5] chore(deps): bump commit-check from 0.5.6 to 0.6.2 (#22) Bumps [commit-check](https://github.com/commit-check/commit-check) from 0.5.6 to 0.6.2. - [Release notes](https://github.com/commit-check/commit-check/releases) - [Commits](https://github.com/commit-check/commit-check/compare/v0.5.6...v0.6.2) --- updated-dependencies: - dependency-name: commit-check dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- requirements.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/requirements.txt b/requirements.txt index be65bd7..2267a0d 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,3 +1,3 @@ # Install commit-check CLI # For details please see: https://github.com/commit-check/commit-check -commit-check==0.5.6 +commit-check==0.6.2