padma-deployment 0.2.0 → 0.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +8 -8
- data/lib/tasks/deployment.rake +25 -13
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
---
|
2
2
|
!binary "U0hBMQ==":
|
3
3
|
metadata.gz: !binary |-
|
4
|
-
|
4
|
+
NDE1ZTBiOTM5ZjJlMzhjNTZmYWFjNjkwZDU2OWIwODZkNTU0YmE2NA==
|
5
5
|
data.tar.gz: !binary |-
|
6
|
-
|
6
|
+
ZGQ3MDJhMmVlZGMyMWViMDEwNmE2MjM3NGIyMmQ5YzZhYjY2MDQ2Yg==
|
7
7
|
SHA512:
|
8
8
|
metadata.gz: !binary |-
|
9
|
-
|
10
|
-
|
11
|
-
|
9
|
+
NmMwYTM0N2RkMThkYzEwYzAyMmZhYjk3NTg1NDhhNjJlMDViMjc0YzU2Yjll
|
10
|
+
NmI1MDJiMjExNGMwNTVlNDFiODdjOTE5ZmI0YmRhYzFmODc3N2QyMjEwNDkx
|
11
|
+
YzAxMWM2NjdiNDQwMGRiYzI2MjU1MTk5NzY5MmU5MDMzNWRmYTA=
|
12
12
|
data.tar.gz: !binary |-
|
13
|
-
|
14
|
-
|
15
|
-
|
13
|
+
Nzc4NzA4Yjk1YjU2ZDM5YTNhZTFiOTdhNmFkMzc4YmY5YmU5MDEwNTBiNTAy
|
14
|
+
ZmQ1NTQ2OTRlODRhNjZlNWE4NWUxODk2Y2YzZjlhMTc4ZDVjMGUzYjRlZDE1
|
15
|
+
YzZlNDYyMDgyMGU1ZTVlMDk2NTNhYjc3MjcxMmM0YzI1N2E5ZmI=
|
data/lib/tasks/deployment.rake
CHANGED
@@ -10,31 +10,43 @@ namespace :deploy do
|
|
10
10
|
desc "deploys to staging server"
|
11
11
|
task :staging do
|
12
12
|
puts "====> deploying to staging..."
|
13
|
-
|
14
|
-
|
15
|
-
rebase_to_master('staging')
|
16
|
-
|
17
|
-
|
13
|
+
run 'git checkout master'
|
14
|
+
run 'git pull'
|
15
|
+
if rebase_to_master('staging')
|
16
|
+
deploy(:staging)
|
17
|
+
end
|
18
|
+
run 'git checkout master'
|
18
19
|
end
|
19
20
|
|
20
21
|
desc "deploys to production server"
|
21
22
|
task :production do
|
22
23
|
puts "====> deploying to production..."
|
23
|
-
|
24
|
-
|
25
|
-
rebase_to_master('production')
|
26
|
-
|
27
|
-
|
24
|
+
run 'git checkout master'
|
25
|
+
run 'git pull'
|
26
|
+
if rebase_to_master('production')
|
27
|
+
deploy(:production)
|
28
|
+
end
|
29
|
+
run 'git checkout master'
|
28
30
|
end
|
29
31
|
|
30
32
|
end
|
31
33
|
|
34
|
+
def run(comand)
|
35
|
+
puts comand
|
36
|
+
`#{comand}`
|
37
|
+
if $?.success?
|
38
|
+
true
|
39
|
+
else
|
40
|
+
raise "'#{comand}' failed. finishing..."
|
41
|
+
end
|
42
|
+
end
|
43
|
+
|
32
44
|
def rebase_to_master(branch_name)
|
33
45
|
if local_branch_exists?(branch_name)
|
34
|
-
|
35
|
-
|
46
|
+
run "git checkout #{branch_name}"
|
47
|
+
run 'git rebase master'
|
36
48
|
else
|
37
|
-
|
49
|
+
run "git checkout -b #{branch_name}"
|
38
50
|
end
|
39
51
|
end
|
40
52
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: padma-deployment
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Dwayne Macgowan
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-02-
|
11
|
+
date: 2014-02-18 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: railties
|