guard-pow 0.1.0 → 0.2.1
Sign up to get free protection for your applications and to get access to all the features.
- data/README.md +73 -0
- data/lib/guard/pow.rb +6 -2
- data/lib/guard/pow/version.rb +1 -1
- metadata +45 -88
- data/README.rdoc +0 -57
data/README.md
ADDED
@@ -0,0 +1,73 @@
|
|
1
|
+
Guard::Pow ![travis-ci](http://travis-ci.org/guard/guard-pow.png)
|
2
|
+
=============
|
3
|
+
|
4
|
+
Pow guard allows to automatically & intelligently restart your applications (just by touching tmp/restart.txt)
|
5
|
+
|
6
|
+
* Tested on Ruby 1.8.6, 1.8.7 & 1.9.2.
|
7
|
+
|
8
|
+
Install
|
9
|
+
-------
|
10
|
+
|
11
|
+
Please be sure to have [Guard](https://github.com/guard/guard) installed before continue.
|
12
|
+
|
13
|
+
Install the gem:
|
14
|
+
|
15
|
+
$ gem install guard-pow
|
16
|
+
|
17
|
+
Add it to your Gemfile (inside development group):
|
18
|
+
|
19
|
+
``` ruby
|
20
|
+
gem 'guard-pow'
|
21
|
+
```
|
22
|
+
|
23
|
+
Add guard definition to your Guardfile by running this command:
|
24
|
+
|
25
|
+
$ guard init pow
|
26
|
+
|
27
|
+
Usage
|
28
|
+
-----
|
29
|
+
|
30
|
+
Please read [Guard usage doc](https://github.com/guard/guard#readme)
|
31
|
+
|
32
|
+
Guardfile
|
33
|
+
---------
|
34
|
+
|
35
|
+
Pow guard can be really be adapated to all kind of projects.
|
36
|
+
Please read [Guard doc](http://github.com/guard/guard#readme) for more info about Guardfile DSL.
|
37
|
+
|
38
|
+
### Rails app
|
39
|
+
|
40
|
+
``` ruby
|
41
|
+
guard 'pow' do
|
42
|
+
watch('.powrc')
|
43
|
+
watch('.powenv')
|
44
|
+
watch('.rvmrc')
|
45
|
+
watch('Gemfile')
|
46
|
+
watch('Gemfile.lock')
|
47
|
+
watch('config/application.rb')
|
48
|
+
watch('config/environment.rb')
|
49
|
+
watch(%r{^config/environments/.*\.rb$})
|
50
|
+
watch(%r{^config/initializers/.*\.rb$})
|
51
|
+
end
|
52
|
+
```
|
53
|
+
|
54
|
+
### List of available options:
|
55
|
+
|
56
|
+
``` ruby
|
57
|
+
:restart_on_start => true # Restart Pow on Guard start, default: false
|
58
|
+
:restart_on_reload => false # Restart Pow on Guard reload, default: true
|
59
|
+
```
|
60
|
+
|
61
|
+
Development
|
62
|
+
-----------
|
63
|
+
|
64
|
+
* Source hosted at [GitHub](https://github.com/guard/guard-rspec)
|
65
|
+
* Report issues/Questions/Feature requests on [GitHub Issues](https://github.com/guard/guard-rspec/issues)
|
66
|
+
|
67
|
+
Pull requests are very welcome! Make sure your patches are well tested. Please create a topic branch for every separate change
|
68
|
+
you make.
|
69
|
+
|
70
|
+
Author
|
71
|
+
------
|
72
|
+
|
73
|
+
[Thibaud Guillaume-Gentil](https://github.com/thibaudgg)
|
data/lib/guard/pow.rb
CHANGED
@@ -9,15 +9,19 @@ module Guard
|
|
9
9
|
|
10
10
|
def initialize(watchers = [], options = {})
|
11
11
|
super
|
12
|
+
@options = {
|
13
|
+
:restart_on_start => false,
|
14
|
+
:restart_on_reload => true
|
15
|
+
}.update(options)
|
12
16
|
@runner = Runner.new
|
13
17
|
end
|
14
18
|
|
15
19
|
def start
|
16
|
-
runner.restart_pow
|
20
|
+
runner.restart_pow if @options[:restart_on_start]
|
17
21
|
end
|
18
22
|
|
19
23
|
def reload
|
20
|
-
runner.restart_pow
|
24
|
+
runner.restart_pow if @options[:restart_on_reload]
|
21
25
|
end
|
22
26
|
|
23
27
|
def run_on_change(paths)
|
data/lib/guard/pow/version.rb
CHANGED
metadata
CHANGED
@@ -1,138 +1,95 @@
|
|
1
|
-
--- !ruby/object:Gem::Specification
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
2
|
name: guard-pow
|
3
|
-
version: !ruby/object:Gem::Version
|
4
|
-
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.2.1
|
5
5
|
prerelease:
|
6
|
-
segments:
|
7
|
-
- 0
|
8
|
-
- 1
|
9
|
-
- 0
|
10
|
-
version: 0.1.0
|
11
6
|
platform: ruby
|
12
|
-
authors:
|
7
|
+
authors:
|
13
8
|
- Thibaud Guillaume-Gentil
|
14
9
|
autorequire:
|
15
10
|
bindir: bin
|
16
11
|
cert_chain: []
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
dependencies:
|
21
|
-
- !ruby/object:Gem::Dependency
|
12
|
+
date: 2011-09-01 00:00:00.000000000Z
|
13
|
+
dependencies:
|
14
|
+
- !ruby/object:Gem::Dependency
|
22
15
|
name: guard
|
23
|
-
|
24
|
-
requirement: &id001 !ruby/object:Gem::Requirement
|
16
|
+
requirement: &70304668055360 !ruby/object:Gem::Requirement
|
25
17
|
none: false
|
26
|
-
requirements:
|
27
|
-
- -
|
28
|
-
- !ruby/object:Gem::Version
|
29
|
-
hash: 19
|
30
|
-
segments:
|
31
|
-
- 0
|
32
|
-
- 3
|
33
|
-
- 0
|
18
|
+
requirements:
|
19
|
+
- - ! '>='
|
20
|
+
- !ruby/object:Gem::Version
|
34
21
|
version: 0.3.0
|
35
22
|
type: :runtime
|
36
|
-
version_requirements: *id001
|
37
|
-
- !ruby/object:Gem::Dependency
|
38
|
-
name: bundler
|
39
23
|
prerelease: false
|
40
|
-
|
24
|
+
version_requirements: *70304668055360
|
25
|
+
- !ruby/object:Gem::Dependency
|
26
|
+
name: bundler
|
27
|
+
requirement: &70304668053960 !ruby/object:Gem::Requirement
|
41
28
|
none: false
|
42
|
-
requirements:
|
29
|
+
requirements:
|
43
30
|
- - ~>
|
44
|
-
- !ruby/object:Gem::Version
|
45
|
-
hash: 1
|
46
|
-
segments:
|
47
|
-
- 1
|
48
|
-
- 0
|
49
|
-
- 11
|
31
|
+
- !ruby/object:Gem::Version
|
50
32
|
version: 1.0.11
|
51
33
|
type: :development
|
52
|
-
version_requirements: *id002
|
53
|
-
- !ruby/object:Gem::Dependency
|
54
|
-
name: rspec
|
55
34
|
prerelease: false
|
56
|
-
|
35
|
+
version_requirements: *70304668053960
|
36
|
+
- !ruby/object:Gem::Dependency
|
37
|
+
name: rspec
|
38
|
+
requirement: &70304668024400 !ruby/object:Gem::Requirement
|
57
39
|
none: false
|
58
|
-
requirements:
|
40
|
+
requirements:
|
59
41
|
- - ~>
|
60
|
-
- !ruby/object:Gem::Version
|
61
|
-
hash: 27
|
62
|
-
segments:
|
63
|
-
- 2
|
64
|
-
- 5
|
65
|
-
- 0
|
42
|
+
- !ruby/object:Gem::Version
|
66
43
|
version: 2.5.0
|
67
44
|
type: :development
|
68
|
-
version_requirements: *id003
|
69
|
-
- !ruby/object:Gem::Dependency
|
70
|
-
name: guard-rspec
|
71
45
|
prerelease: false
|
72
|
-
|
46
|
+
version_requirements: *70304668024400
|
47
|
+
- !ruby/object:Gem::Dependency
|
48
|
+
name: guard-rspec
|
49
|
+
requirement: &70304668023500 !ruby/object:Gem::Requirement
|
73
50
|
none: false
|
74
|
-
requirements:
|
51
|
+
requirements:
|
75
52
|
- - ~>
|
76
|
-
- !ruby/object:Gem::Version
|
77
|
-
hash: 23
|
78
|
-
segments:
|
79
|
-
- 0
|
80
|
-
- 2
|
81
|
-
- 0
|
53
|
+
- !ruby/object:Gem::Version
|
82
54
|
version: 0.2.0
|
83
55
|
type: :development
|
84
|
-
|
56
|
+
prerelease: false
|
57
|
+
version_requirements: *70304668023500
|
85
58
|
description: Guard::Pow automatically manage Pow applications restart
|
86
|
-
email:
|
59
|
+
email:
|
87
60
|
- thibaud@thibaud.me
|
88
61
|
executables: []
|
89
|
-
|
90
62
|
extensions: []
|
91
|
-
|
92
63
|
extra_rdoc_files: []
|
93
|
-
|
94
|
-
files:
|
64
|
+
files:
|
95
65
|
- lib/guard/pow/runner.rb
|
96
66
|
- lib/guard/pow/templates/Guardfile
|
97
67
|
- lib/guard/pow/version.rb
|
98
68
|
- lib/guard/pow.rb
|
99
69
|
- LICENSE
|
100
|
-
- README.
|
101
|
-
has_rdoc: true
|
70
|
+
- README.md
|
102
71
|
homepage: http://rubygems.org/gems/guard-pow
|
103
72
|
licenses: []
|
104
|
-
|
105
73
|
post_install_message:
|
106
74
|
rdoc_options: []
|
107
|
-
|
108
|
-
require_paths:
|
75
|
+
require_paths:
|
109
76
|
- lib
|
110
|
-
required_ruby_version: !ruby/object:Gem::Requirement
|
77
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
111
78
|
none: false
|
112
|
-
requirements:
|
113
|
-
- -
|
114
|
-
- !ruby/object:Gem::Version
|
115
|
-
|
116
|
-
|
117
|
-
- 0
|
118
|
-
version: "0"
|
119
|
-
required_rubygems_version: !ruby/object:Gem::Requirement
|
79
|
+
requirements:
|
80
|
+
- - ! '>='
|
81
|
+
- !ruby/object:Gem::Version
|
82
|
+
version: '0'
|
83
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
120
84
|
none: false
|
121
|
-
requirements:
|
122
|
-
- -
|
123
|
-
- !ruby/object:Gem::Version
|
124
|
-
hash: 23
|
125
|
-
segments:
|
126
|
-
- 1
|
127
|
-
- 3
|
128
|
-
- 6
|
85
|
+
requirements:
|
86
|
+
- - ! '>='
|
87
|
+
- !ruby/object:Gem::Version
|
129
88
|
version: 1.3.6
|
130
89
|
requirements: []
|
131
|
-
|
132
90
|
rubyforge_project: guard-pow
|
133
|
-
rubygems_version: 1.
|
91
|
+
rubygems_version: 1.8.10
|
134
92
|
signing_key:
|
135
93
|
specification_version: 3
|
136
94
|
summary: Guard gem for Pow
|
137
95
|
test_files: []
|
138
|
-
|
data/README.rdoc
DELETED
@@ -1,57 +0,0 @@
|
|
1
|
-
= Guard::Pow
|
2
|
-
|
3
|
-
Pow guard allows to automatically & intelligently restart your applications (just by touching tmp/restart.txt)
|
4
|
-
|
5
|
-
- Tested on Ruby 1.8.6, 1.8.7 & 1.9.2.
|
6
|
-
|
7
|
-
== Install
|
8
|
-
|
9
|
-
Please be sure to have {Guard}[http://github.com/guard/guard] installed before continue.
|
10
|
-
|
11
|
-
Install the gem:
|
12
|
-
|
13
|
-
gem install guard-pow
|
14
|
-
|
15
|
-
Add it to your Gemfile (inside test group):
|
16
|
-
|
17
|
-
gem 'guard-pow'
|
18
|
-
|
19
|
-
Add guard definition to your Guardfile with:
|
20
|
-
|
21
|
-
guard init pow
|
22
|
-
|
23
|
-
== Usage
|
24
|
-
|
25
|
-
Please read {Guard usage doc}[http://github.com/guard/guard#readme]
|
26
|
-
|
27
|
-
== Guardfile
|
28
|
-
|
29
|
-
Pow guard can be really be adapated to all kind of projects.
|
30
|
-
Please read {Guard doc}[http://github.com/guard/guard#readme] for more info about Guardfile DSL.
|
31
|
-
|
32
|
-
=== Rails app
|
33
|
-
|
34
|
-
guard 'pow' do
|
35
|
-
watch('.powrc')
|
36
|
-
watch('.powenv')
|
37
|
-
watch('.rvmrc')
|
38
|
-
watch('Gemfile')
|
39
|
-
watch('Gemfile.lock')
|
40
|
-
watch('config/application.rb')
|
41
|
-
watch('config/environment.rb')
|
42
|
-
watch(%r{^config/environments/.*\.rb$})
|
43
|
-
watch(%r{^config/initializers/.*\.rb$})
|
44
|
-
end
|
45
|
-
|
46
|
-
|
47
|
-
== Development
|
48
|
-
|
49
|
-
- Source hosted at {GitHub}[http://github.com/guard/guard-pow]
|
50
|
-
- Report issues/Questions/Feature requests on {GitHub Issues}[http://github.com/guard/guard-pow/issues]
|
51
|
-
|
52
|
-
Pull requests are very welcome! Make sure your patches are well tested. Please create a topic branch for every separate change
|
53
|
-
you make.
|
54
|
-
|
55
|
-
== Authors
|
56
|
-
|
57
|
-
{Thibaud Guillaume-Gentil}[http://github.com/thibaudgg]
|