Browse code

fixed variables for github in rakefile

B Mathis authored on 24/11/2009 at 23:15:37
Showing 1 changed files
... ...
@@ -103,13 +103,14 @@ multitask :deploy_github => [:default, :clean_debug] do
103 103
   require 'git'
104 104
   repo = Git.open('.')
105 105
   repo.branch("#{deploy_branch}").checkout
106
-  (Dir["*"] - ["#{site}/*"]).each { |f| rm_rf(f) }
106
+  (Dir["*"] - [site]).each { |f| rm_rf(f) }
107 107
   Dir["#{site}/*"].each {|f| mv(f, ".")}
108
-  rm_rf("#{site}/*")
108
+  rm_rf(site)
109 109
   Dir["**/*"].each {|f| repo.add(f) }
110 110
   repo.status.deleted.each {|f, s| repo.remove(f)}
111 111
   message = ENV["MESSAGE"] || "Site updated at #{Time.now.utc}"
112 112
   repo.commit(message)
113
+  repo.push("#{deploy_branch} origin")
113 114
   repo.branch("#{source_branch}").checkout
114 115
 end
115 116