front 0.1.2 → 0.1.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +8 -8
- data/CHANGELOG.md +5 -0
- data/lib/front/cli/vagrant.rb +0 -45
- data/lib/front/version.rb +1 -1
- metadata +2 -1
checksums.yaml
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
---
|
2
2
|
!binary "U0hBMQ==":
|
3
3
|
metadata.gz: !binary |-
|
4
|
-
|
4
|
+
MDU2NTNiZjVhMTA4YjNjMDk3NzRhNjZiYWQ1NDc0NWYxNWY0N2VhOA==
|
5
5
|
data.tar.gz: !binary |-
|
6
|
-
|
6
|
+
NzBlYzI3NWQ3NTQyZTYyZWViYmM5YTA1MmFjZDU5MmUyMDczOGEwZQ==
|
7
7
|
!binary "U0hBNTEy":
|
8
8
|
metadata.gz: !binary |-
|
9
|
-
|
10
|
-
|
11
|
-
|
9
|
+
NWRmOGMyNmY2MmVjNTUxM2I0MDdmOGQxMmI5MjY2NjNkMTA2ZTRjNGQ2MjAx
|
10
|
+
OTRkMGEyY2U2NmNkZTg2NTk5MWZlMTNlYzgyNDc3ZGRmNmFkODhkNGMzYmI5
|
11
|
+
YTZhNDcwYjVjMjRhZmZhNWY2YjJjYWYxN2VjOWE5N2EyY2UzODM=
|
12
12
|
data.tar.gz: !binary |-
|
13
|
-
|
14
|
-
|
15
|
-
|
13
|
+
ZjAzM2VkMmNlMzJhYTNhYWZjMjQ0OTJlZDM2NWIxOTI2NGUyMDZiZTdjMGZj
|
14
|
+
ODJhZmI1N2E5MDZjMTRlOWU1Mjc3MTJmMTAxMWRlYTRiOWJhZGEwYWFlMTNm
|
15
|
+
OTZlYmE0OWUzZDJhMmVmMTg3MjgyMDk3YjZhNDJhNDAwZGEyYmQ=
|
data/CHANGELOG.md
ADDED
data/lib/front/cli/vagrant.rb
CHANGED
@@ -1,7 +1,5 @@
|
|
1
1
|
module Front
|
2
2
|
module CLI
|
3
|
-
require 'resque'
|
4
|
-
|
5
3
|
class Vagrant
|
6
4
|
attr_reader :id
|
7
5
|
attr_reader :path
|
@@ -72,54 +70,11 @@ module Front
|
|
72
70
|
end
|
73
71
|
end
|
74
72
|
|
75
|
-
def run2(cmd)
|
76
|
-
options = {}
|
77
|
-
options[:chdir] = path
|
78
|
-
unless wait
|
79
|
-
log_file = "#{path}/front.log"
|
80
|
-
options[:out] = log_file
|
81
|
-
options[:err] = log_file
|
82
|
-
end
|
83
|
-
|
84
|
-
pid = Kernel.spawn("vagrant #{cmd}", options)
|
85
|
-
if wait
|
86
|
-
Process.wait pid
|
87
|
-
else
|
88
|
-
Process.detach pid
|
89
|
-
end
|
90
|
-
end
|
91
|
-
|
92
73
|
def capture(cmd)
|
93
74
|
Dir.chdir(path) do
|
94
75
|
`vagrant #{cmd}`
|
95
76
|
end
|
96
77
|
end
|
97
78
|
end
|
98
|
-
|
99
|
-
class VagrantWorker
|
100
|
-
@queue = :vagrant
|
101
|
-
|
102
|
-
def self.perform(task)
|
103
|
-
cmd = task.cmd
|
104
|
-
options = task.options
|
105
|
-
options[:out] = task.log_file
|
106
|
-
options[:err] = task.log_file
|
107
|
-
|
108
|
-
pid = Kernel.spawn(cmd, options)
|
109
|
-
Process.wait pid
|
110
|
-
end
|
111
|
-
end
|
112
|
-
|
113
|
-
class VagrantTask
|
114
|
-
attr_accessor :cmd
|
115
|
-
attr_accessor :options
|
116
|
-
attr_accessor :log_file
|
117
|
-
|
118
|
-
def initialize(cmd, options, log_file)
|
119
|
-
@cmd = cmd
|
120
|
-
@options = options
|
121
|
-
@log_file = log_file
|
122
|
-
end
|
123
|
-
end
|
124
79
|
end
|
125
80
|
end
|
data/lib/front/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: front
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Darshan Sawardekar
|
@@ -47,6 +47,7 @@ extensions: []
|
|
47
47
|
extra_rdoc_files: []
|
48
48
|
files:
|
49
49
|
- .gitignore
|
50
|
+
- CHANGELOG.md
|
50
51
|
- Gemfile
|
51
52
|
- LICENSE.txt
|
52
53
|
- README.md
|