Skip to content

Commit

Permalink
tools: Update scripts
Browse files Browse the repository at this point in the history
  • Loading branch information
taiki-e committed Mar 2, 2025
1 parent 8777561 commit 916a512
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 15 deletions.
20 changes: 6 additions & 14 deletions tools/publish.sh
Original file line number Diff line number Diff line change
Expand Up @@ -117,18 +117,14 @@ fi
set -x

git tag "${tag}"
retry git push origin main
retry git push origin --tags
retry git push origin refs/heads/main
retry git push origin refs/tags/"${tag}"

major_version_tag="v${version%%.*}"
git checkout -b "${major_version_tag}"
retry git push origin refs/heads/"${major_version_tag}"
if git --no-pager tag | grep -Eq "^${major_version_tag}$"; then
git tag -d "${major_version_tag}"
retry git push --delete origin refs/tags/"${major_version_tag}"
fi
git tag "${major_version_tag}"
retry git push origin --tags
git tag -f "${major_version_tag}"
retry git push origin -f refs/tags/"${major_version_tag}"
git checkout main
git branch -d "${major_version_tag}"

Expand All @@ -150,12 +146,8 @@ for tool in "${tools[@]}"; do
git add action.yml
git commit -m "${tool}"
retry git push origin -f refs/heads/"${tool}"
if git --no-pager tag | grep -Eq "^${tool}$"; then
git tag -d "${tool}"
retry git push --delete origin refs/tags/"${tool}"
fi
git tag "${tool}"
retry git push origin --tags
git tag -f "${tool}"
retry git push origin -f refs/tags/"${tool}"
git checkout main
git branch -D "${tool}"
done
Expand Down
2 changes: 1 addition & 1 deletion tools/tidy.sh
Original file line number Diff line number Diff line change
Expand Up @@ -666,7 +666,7 @@ elif check_install shellcheck; then
if [[ ${#docker_files[@]} -gt 0 ]]; then
# Exclude SC2096 due to the way the temporary script is created.
shellcheck_exclude=SC2096
info "running \`shellcheck --exclude ${shellcheck_exclude}\` for scripts in \$(git ls-files '*Dockerfile*')\`"
info "running \`shellcheck --exclude ${shellcheck_exclude}\` for scripts in \`\$(git ls-files '*Dockerfile*')\`"
if check_install jq python3 parse-dockerfile; then
shellcheck_for_dockerfile() {
local text=$1
Expand Down

0 comments on commit 916a512

Please sign in to comment.