Permalink
Browse files

Merge branch 'master' of https://github.com/charliesome/voze

  • Loading branch information...
2 parents 0fee632 + 7661323 commit 85b26ad97dec8d3e7b203f108e3fd255a5994ed2 @kittens kittens committed Jun 19, 2012
View
16 Makefile
@@ -1,16 +0,0 @@
-PRODUCTION_HOST=voze.org
-PRODUCTION_USER=voze
-PRODUCTION_DIR=/srv/http/voze/rails
-
-deploy:
- ssh $(PRODUCTION_USER)@$(PRODUCTION_HOST) \
- 'cd $(PRODUCTION_DIR) && git reset --hard HEAD && git pull && make prod-deploy'
-
-# all targets starting with prod- are intended to be run automatically on the
-# production machine. do not run them manually
-
-prod-deploy:
- sudo bundle install
- bundle exec rake assets:precompile RAILS_ENV=production
- bundle exec rake db:migrate RAILS_ENV=production
- touch tmp/restart.txt
View
2 app/assets/javascripts/sessions.js.coffee
@@ -2,7 +2,7 @@ return false if not do $('section.sessions').size
flash = (elem, lag=350, opacity=0.5, times=2, time=75) ->
next = ->
- elem.stop(true).animate opacity: opacity, time, ->
+ elem.stop(true).delay(lag).animate opacity: opacity, time, ->
elem.animate opacity: 1, time, ->
do next if --times isnt 0
do next
View
4 app/helpers/application_helper.rb
@@ -8,4 +8,8 @@ def current_user
end
end
end
+
+ def personal_announce_url
+ announce_url auth_token: current_user.auth_token
+ end
end
View
4 app/helpers/versions_helper.rb
@@ -1,8 +1,4 @@
module VersionsHelper
- def personal_announce_url
- announce_url auth_token: current_user.auth_token
- end
-
def render_metadata(section)
partial_name = "#{@torrent.metadata.class.name.underscore}/#{section}"
render partial: partial_name, locals: { metadata: @torrent.metadata }
View
2 app/views/password_resets/new.html.erb
@@ -7,7 +7,7 @@
<%= f.text_field :username, placeholder: "Username or email" %>
</div>
<footer>
- <%= f.submit "Reset", { class: "blue left", id: "session_submit" } %>
+ <%= f.submit "Reset", class: "blue left", id: "session_submit" %>
<div class="icon loading left"></div>
<%= link_to "Cancel", new_sessions_path, class: "right" %>
</footer>
View
2 app/views/sessions/new.html.erb
@@ -21,7 +21,7 @@
<input type="hidden" name="redirect_to" value="<%= flash[:redirect_to] %>" />
<% end %>
<footer>
- <%= f.submit "Sign in", { class: "blue left", id: "session_submit" } %>
+ <%= f.submit "Sign in", class: "blue left", id: "session_submit" %>
<div class="icon loading left"></div>
<%= link_to "Forgot your password?", new_password_reset_path, class: "right" %>
</footer>
View
2 app/views/users/new.html.erb
@@ -38,7 +38,7 @@
<%= f.text_field :invite_code, placeholder: "Invite code" %>
</div>
<footer>
- <%= f.submit "Sign up", { class: "blue left", id: "session_submit" } %>
+ <%= f.submit "Sign up", class: "blue left", id: "session_submit" %>
<div class="icon loading left"></div>
<%= link_to "Already have an account?", new_sessions_path, class: "right" %>
</footer>
View
17 lib/tasks/deploy.rake
@@ -0,0 +1,17 @@
+task :deploy do
+ production_host = "voze.org"
+ production_user = "voze"
+ production_dir = "/srv/http/voze"
+
+ cmds = [
+ "cd #{production_dir}",
+ "git reset --hard",
+ "git pull",
+ "sudo bundle install",
+ "bundle exec rake assets:precompile RAILS_ENV=production",
+ "bundle exec rake db:migrate RAILS_ENV=production",
+ "touch tmp/restart.txt"
+ ]
+
+ system "ssh #{production_user}@#{production_host} '#{cmds.join " && "}'"
+end

0 comments on commit 85b26ad

Please sign in to comment.