Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-docs.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAchilleas Pipinellis <axilleas@axilleas.me>2017-09-04 22:07:46 +0300
committerAchilleas Pipinellis <axilleas@axilleas.me>2017-09-04 22:07:46 +0300
commit827b337bbb77b84ce4b8cd2d01f8c7a183ad15d1 (patch)
tree99a206e6b2e53df3773a5c26ecd09538f3746983 /Rakefile
parentd30dbb97e189297c4179652668125d78cc1a796a (diff)
Fetch and reset rather than pull to avoid merge conflicts
Diffstat (limited to 'Rakefile')
-rw-r--r--Rakefile6
1 files changed, 4 insertions, 2 deletions
diff --git a/Rakefile b/Rakefile
index 119a24ca..9465f52b 100644
--- a/Rakefile
+++ b/Rakefile
@@ -74,8 +74,10 @@ task :pull_repos do
# Enter the temporary directory and return after block is completed.
FileUtils.cd(temp_dir) do
- # Update repository from master.
- `git pull origin #{branch}`
+ # Update repository from master. Fetch and reset to avoid
+ # merge conflicts
+ `git fetch origin #{branch}`
+ `git reset --hard origin/#{branch}`
end
else
puts "This shouldn't happen"