Skip to content

Commit 2a7e2d5

Browse files
Skip git pull when skip_push is set
When using skip_push parameter, we should also skip git pull since the branch might not have upstream tracking (e.g., during testing).
1 parent c9e9ca0 commit 2a7e2d5

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

rakelib/release.rake

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -86,8 +86,8 @@ task :release, %i[version dry_run registry skip_push] do |_t, args|
8686
# Delete any react_on_rails_pro.gemspec except the one in react_on_rails_pro directory
8787
sh_in_dir(gem_root, "find . -mindepth 3 -name 'react_on_rails_pro.gemspec' -delete")
8888

89-
# Pull latest changes (skip in dry-run mode)
90-
sh_in_dir(gem_root, "git pull --rebase") unless is_dry_run
89+
# Pull latest changes (skip in dry-run mode or when skip_push is set)
90+
sh_in_dir(gem_root, "git pull --rebase") unless is_dry_run || skip_push
9191

9292
# Determine if version_input is semver keyword or explicit version
9393
semver_keywords = %w[patch minor major]

0 commit comments

Comments
 (0)