diff --git a/backup/Rakefile b/backup/Rakefile
index 60eccece92e307156a236340a02798a4cf07650f..5e496456744fa787ccb2bea27e48c0f1f522173d 100644
--- a/backup/Rakefile
+++ b/backup/Rakefile
@@ -193,13 +193,13 @@ end
 def init_git_repository(repository)
   title "Initializing git repository #{repository}", 2
   path = File.join(LOCAL_GIT_PATH)
-  shell "cd #{path} && git clone #{repository}"
+  shell "cd #{path} && git clone --bare #{repository}"
 end
 
 def sync_git_repository(repository)
   title "Syncing repository #{repository}", 2
   path = File.join(LOCAL_GIT_PATH, repository)
-  shell "cd #{path} && git pull"
+  shell "cd #{path} && git fetch origin"
 end
 
 def rdiff_get(source, destination)
@@ -240,7 +240,7 @@ namespace :backup do
     file = File.new(LOCAL_GITLIST_PATH, "r")
     while (repository = file.gets)
       repository.strip!
-      repository_folder = repository.split('/').last.gsub('.git','')
+      repository_folder = repository.split('/').last
       init_git_repository(repository) unless git_exists?(repository_folder)
       sync_git_repository(repository_folder)
     end