Skip to content

Commit 49feb12

Browse files
authored
chore(scripts): remove branch checks from release script (coder#14184)
The initial assumption that branch manipulations should be done by this script and not pushed to remote manually has proven to get in the way of the regular release flow. These are just safety-checks to prevent user error, safe to remove. Fixes coder#13648
1 parent 89e6afb commit 49feb12

File tree

2 files changed

+0
-10
lines changed

2 files changed

+0
-10
lines changed

scripts/release.sh

-6
Original file line numberDiff line numberDiff line change
@@ -165,12 +165,6 @@ if [[ ${script_check} = 1 ]] && [[ -n ${script_diff} ]]; then
165165
error "Release script is out-of-date. Please check out the latest version and try again."
166166
fi
167167

168-
# Make sure no other remote release contains this ref.
169-
release_contains_ref="$(git branch --remotes --contains "${ref}" --list "${remote}/release/*" --format='%(refname)')"
170-
if [[ -n ${release_contains_ref} ]]; then
171-
error "Ref ${ref_name} is already part of another release: $(git describe --always "${ref}") on ${release_contains_ref#"refs/remotes/${remote}/"}."
172-
fi
173-
174168
log "Checking GitHub for latest release(s)..."
175169

176170
# Check the latest version tag from GitHub (by version) using the API.

scripts/release/tag_version.sh

-4
Original file line numberDiff line numberDiff line change
@@ -171,10 +171,6 @@ else
171171
fi
172172
fi
173173

174-
if [[ -n ${remote_branch_exists} ]]; then
175-
error "Release branch ${release_branch} already exists on remote, please check your ref."
176-
fi
177-
178174
if [[ -n ${local_branch_exists} ]]; then
179175
# If it exists, ensure that this release branch points to the provided ref.
180176
release_branch_ref=$(git rev-parse "${release_branch}")

0 commit comments

Comments
 (0)