guard-gulp 0.0.1 → 0.0.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 3ff23354d4d9347461db4bd99592a740390a24fe
4
- data.tar.gz: eb9b2723f47693d98dd2988e1dd105e9aac630b1
3
+ metadata.gz: 8b9cb5e7c4a2044d6b7ee1fb32ff5e9e68d6a266
4
+ data.tar.gz: b8a6240568611e1b9db0034e451660a686095b23
5
5
  SHA512:
6
- metadata.gz: 917e211c0d12259fc76eb8bd66c2038681f623aa34f42d3c122f807edec65a9052883b1147e5f4022cf7f601c074c0dbeb2d1134ffe79e0692a21e2ca3a35fc7
7
- data.tar.gz: 9fc53596ace2cdcd77d92328e2e9716c1eb6e308fd541476fb4922a4fa30317d8fa235fe5846fbb86198d6ac8aa47e27c198de5d57b18c61831b51923f329048
6
+ metadata.gz: 687f500c31041743984c2a8e3b038b6b41315762a2856f50fd740711996cc80dc5f6017041d7c5974dc989b37d6fc77c8de50dcbca639bd6c7f562d758153d0f
7
+ data.tar.gz: 09dad7e134b8a1ff2983cf3ce517388cd467e438de2e5e903e51a3336afaa43141c8e8292c8d08e594565829de8b328349f799dfc016b9afa9bf98e6fb69b23c
@@ -0,0 +1,2 @@
1
+ *.gem*
2
+ Gemfile.lock
data/LICENSE ADDED
@@ -0,0 +1,22 @@
1
+ The MIT LICENSE
2
+
3
+ Copyright (c) 2014 Wegowise Inc.
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining
6
+ a copy of this software and associated documentation files (the
7
+ "Software"), to deal in the Software without restriction, including
8
+ without limitation the rights to use, copy, modify, merge, publish,
9
+ distribute, sublicense, and/or sell copies of the Software, and to
10
+ permit persons to whom the Software is furnished to do so, subject to
11
+ the following conditions:
12
+
13
+ The above copyright notice and this permission notice shall be
14
+ included in all copies or substantial portions of the Software.
15
+
16
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
17
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
18
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
19
+ NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
20
+ LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
21
+ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
22
+ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
@@ -0,0 +1,39 @@
1
+ # guard-gulp
2
+
3
+ Guard::Gulp is a [Guard](http://guardgem.org/) plugin to automatically
4
+ start/stop/restart gulp.
5
+
6
+ ### Getting Started
7
+
8
+ If you're using Bundler, you can add guard-gulp to your Gemfile:
9
+
10
+ ```ruby
11
+ gem 'guard-gulp'
12
+ ```
13
+
14
+ Or manually install the guard-gulp gem:
15
+
16
+ ```shell
17
+ gem install guard-gulp
18
+ ```
19
+
20
+ Add the guard definition to your Guardfile by running this command:
21
+
22
+ ```shell
23
+ guard init gulp
24
+ ```
25
+
26
+ Don't forget to [install
27
+ Gulp](https://github.com/gulpjs/gulp/blob/master/docs/getting-started.md#getting-started)!
28
+
29
+ ### Guardfile
30
+
31
+ ```ruby
32
+ guard 'gulp' do
33
+ watch(%r{^gulpfile.js$})
34
+ end
35
+ ```
36
+
37
+ ### Contributing
38
+
39
+ Fork, branch, and pull-request.
@@ -1,5 +1,7 @@
1
1
  require 'guard'
2
2
  require 'guard/guard'
3
+ require 'mkmf'
4
+ require 'timeout'
3
5
 
4
6
  module Guard
5
7
  class Gulp < Guard
@@ -8,10 +10,12 @@ module Guard
8
10
  def initialize(watchers = [], options = {})
9
11
  @options = options
10
12
  @pid = nil
13
+ @gulp_installed = gulp_installed?
11
14
  super
12
15
  end
13
16
 
14
17
  def start
18
+ return unless @gulp_installed
15
19
  stop
16
20
  UI.info 'Starting gulp...'
17
21
  UI.info cmd
@@ -71,5 +75,14 @@ module Guard
71
75
  def env
72
76
  {}
73
77
  end
78
+
79
+ def gulp_installed?
80
+ if find_executable 'gulp'
81
+ true
82
+ else
83
+ UI.error 'Please install gulp!'
84
+ false
85
+ end
86
+ end
74
87
  end
75
88
  end
@@ -1,5 +1,5 @@
1
1
  module Guard
2
2
  module GulpVersion
3
- VERSION = '0.0.1'
3
+ VERSION = '0.0.2'
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: guard-gulp
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Nathan Fixler
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-10-02 00:00:00.000000000 Z
11
+ date: 2014-10-03 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: guard
@@ -31,8 +31,11 @@ executables: []
31
31
  extensions: []
32
32
  extra_rdoc_files: []
33
33
  files:
34
+ - ".gitignore"
34
35
  - ".ruby-version"
35
36
  - Gemfile
37
+ - LICENSE
38
+ - README.md
36
39
  - guard-gulp.gemspec
37
40
  - lib/guard-gulp.rb
38
41
  - lib/guard/gulp.rb