-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathcapfile
61 lines (51 loc) · 1.16 KB
/
capfile
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
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
set :deploy_to, "/home/tdas/alaveteli"
set :app_branch, "tuderechoasaber.es"
set :theme, "tuderechoasaber-theme"
set :port, 22021
role :app, "tdas@tdas"
namespace :app do
desc "Update app code"
task :update_code do
run "cd #{deploy_to} && git pull origin #{app_branch}"
end
desc "Update theme"
task :update_theme do
run "cd #{File.join(deploy_to,'vendor','plugins',theme)} && git pull origin master"
end
desc "Touch restart.txt to reload app"
task :reload do
run "touch #{File.join(deploy_to,'tmp','restart.txt')}"
end
desc "Update the whole thing"
task :update do
update_theme
update_code
reload
end
end
desc "Update locales from Transifex"
namespace :update_tx do
task :default do
es
ca
gl
eu
app::reload
end
desc "Update Spanish locale"
task :es do
run "cd #{deploy_to} && tx pull -l es -f"
end
desc "Update Catalan locale"
task :ca do
run "cd #{deploy_to} && tx pull -l ca -f"
end
desc "Update Basque locale"
task :eu do
run "cd #{deploy_to} && tx pull -l eu -f"
end
desc "Update Galician locale"
task :gl do
run "cd #{deploy_to} && tx pull -l gl -f"
end
end