Skip to content

Commit

Permalink
Merge pull request #651 from akinomyoga/indent
Browse files Browse the repository at this point in the history
Fix indentation
  • Loading branch information
martin-schulze-vireso committed Sep 18, 2022
2 parents 9823861 + def9ee0 commit 008e8ce
Show file tree
Hide file tree
Showing 183 changed files with 2,418 additions and 2,295 deletions.
3 changes: 3 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -30,3 +30,6 @@ tab_width = 4
# trailing spaces indicates word wrap
trim_trailing_spaces = false
trim_trailing_whitespace = false

[test/fixtures/bats/*_no_shellcheck.bats]
ignore = true
2 changes: 1 addition & 1 deletion .github/workflows/check_pr_label.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/usr/bin/bash

get_pr_json() {
curl -s -H "Accept: application/vnd.github.v3+json" "https://api.github.com/repos/bats-core/bats-core/pulls/$1"
curl -s -H "Accept: application/vnd.github.v3+json" "https://api.github.com/repos/bats-core/bats-core/pulls/$1"
}

PR_NUMBER="$1"
Expand Down
10 changes: 10 additions & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,16 @@ jobs:
grep "#${{github.event.pull_request.number}}" docs/CHANGELOG.md
fi
if: ${{github.event.pull_request}}

shfmt:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v2
- run: |
curl https://github.com/mvdan/sh/releases/download/v3.5.1/shfmt_v3.5.1_linux_amd64 -o shfmt
chmod a+x shfmt
- run: ./shfmt --diff .

shellcheck:
runs-on: ubuntu-20.04
steps:
Expand Down
4 changes: 2 additions & 2 deletions bin/bats
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@ fallback_to_readlinkf_posix() {
while [ "$max_symlinks" -ge 0 ] && max_symlinks=$((max_symlinks - 1)); do
if [ ! "$target" = "${target%/*}" ]; then
case $target in
/*) cd -P "${target%/*}/" 2>/dev/null || break ;;
*) cd -P "./${target%/*}" 2>/dev/null || break ;;
/*) cd -P "${target%/*}/" 2>/dev/null || break ;;
*) cd -P "./${target%/*}" 2>/dev/null || break ;;
esac
target=${target##*/}
fi
Expand Down
16 changes: 8 additions & 8 deletions contrib/release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -65,14 +65,14 @@ git commit -m "feat: release Bats v${NEW_BATS_VERSION}"
# changelog start
EOF

local DELIM
DELIM=$(echo -en "\001");
sed -E -n "\\${DELIM}^## \[${NEW_BATS_VERSION}\]${DELIM},\\${DELIM}^## ${DELIM}p" docs/CHANGELOG.md \
| head -n -1 \
| sed -E \
-e 's,^## \[([0-9\.]+)] - (.*),Bats \1\n\nReleased: \2,' \
-e 's,^### (.*),\1:,g' \
| tee "${BATS_RELEASE_NOTES}"
local DELIM
DELIM=$(echo -en "\001")
sed -E -n "\\${DELIM}^## \[${NEW_BATS_VERSION}\]${DELIM},\\${DELIM}^## ${DELIM}p" docs/CHANGELOG.md |
head -n -1 |
sed -E \
-e 's,^## \[([0-9\.]+)] - (.*),Bats \1\n\nReleased: \2,' \
-e 's,^### (.*),\1:,g' |
tee "${BATS_RELEASE_NOTES}"

cat <<EOF
# changelog end
Expand Down

0 comments on commit 008e8ce

Please sign in to comment.