-
Notifications
You must be signed in to change notification settings - Fork 0
/
Rakefile
32 lines (26 loc) · 993 Bytes
/
Rakefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
#!/usr/bin/env rake
# Add your own tasks in files placed in lib/tasks ending in .rake,
# for example lib/tasks/capistrano.rake, and they will automatically be available to Rake.
require File.expand_path('../config/application', __FILE__)
Cartridge::Application.load_tasks
namespace :assets do
desc 'Compile sass and coffeescript files and repackage jammit assets'
task :generate => :environment do
`compass compile --force`
# Recompile coffeescript only if necessary, use rake barista:brew to force
# recompilation
Barista.compile_all! false, false
require 'jammit'
Jammit.package!
end
end
# from https://gist.github.com/862102
desc 'Check Jammit packaging status'
task :before_deploy => :environment do
Rake::Task['assets:precompile'].execute
system "git add #{Rails.root}/public/assets/. && git commit -m 'automatically updated assets'"
end
task :deploy => :before_deploy do
system "git push origin master"
system "git push production master"
end