guard-jekyll-plus 1.4.8 → 1.4.9

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,15 +1,15 @@
1
1
  ---
2
2
  !binary "U0hBMQ==":
3
3
  metadata.gz: !binary |-
4
- NTM1NTg4OGZiZGI5YmFjNThlNGQ0ZjBjYjY5MjhlNzBlYjZkZTJmMA==
4
+ M2EwMWM0NTI0ZTg3ODRmYWQxNGE3ZDhkMmU1YTRiNzY4YzJhZmQ5OA==
5
5
  data.tar.gz: !binary |-
6
- N2JmYjAwNmM0ZGY1MDhmOWM3MTliMTcyNzJjOTdjODhmY2VhYmViNQ==
6
+ OWQ3ZDMwNjc0MWJmYmZmMmJkMDIzZWNkNzk3MDkxYzg5NjI4ZWM1Ng==
7
7
  !binary "U0hBNTEy":
8
8
  metadata.gz: !binary |-
9
- NTEwMTAyMjcwMDZkMjk3Y2E5OGFhNTAzMDA5ODhjYzE5N2YwZmM4YTQzMmMz
10
- OWM1ZjFiZmNhM2M4MjI1MjJjODA1YTk2ODM5MTJjOGY3YjYyMzY3NjY2NTNm
11
- NGZmYjdhNDM2ZjAwMTgyYjkyMGJmNjhmYWI1MGE5NzYwYjFmN2I=
9
+ OTE0ZTUxY2M5ZDI5ZjdmOGIxOTM0Y2UxOTQ4OWZiZTQ5ZDVjMDcwNTVlMDRj
10
+ NmU1NTBiODE4MWRiMzFiMTVhNTIyYmRiMGNlNDE2NDZlY2FmNjllOWY2Y2M4
11
+ NjQxYmIyNTMwN2U2MTBiNDI4ZjQ3MzE2ODY1MmE2OTcwMjY2M2Y=
12
12
  data.tar.gz: !binary |-
13
- NjkyMTg3OGE3ODM0MTZjNzExMTg2MDM0NDA1NmU3NzMwODQzNWUxMmU4ZWM1
14
- ZTQ1MmNiMDk1ZmY1N2IxYzdlY2JmNzZlNzJhN2EyOGU3ZTczZmRiNjkyMDQ1
15
- NGViZDQ2NmFlNjNjYTJjMzkyNzU0M2JiZTZlNDMzYWIzNjkwMDE=
13
+ ZjY3NWQwMDllZDk1ZWIyYTMzYzE3NDk1YzZhNmZmYjMzMmY5NTI5ODc0NDNm
14
+ NmI1MDQ0NTJhMjRiYjE1YzJmMTI5ZThkZWE3MjIzOGMwOGM1OWM1NDY4ZDk2
15
+ YzhkOTY1MDI0YWMxMjJiZTgwZDczZTQ4YjdkZWQxYzdiYzkwZTc=
data/CHANGELOG.md CHANGED
@@ -78,4 +78,8 @@ New config options
78
78
 
79
79
  ### 1.4.8
80
80
 
81
- - Added a way to ignore Guard Stitch Plus's source files
81
+ - Added a way to ignore Guard Stitch Plus's source files.
82
+
83
+ ### 1.4.9
84
+
85
+ - Fix: Copying files ensures that there are files to copy before printing its message.
@@ -140,26 +140,28 @@ module Guard
140
140
  #
141
141
  def copy(files=[])
142
142
  files = ignore_stitch_sources files
143
- begin
144
- message = 'copied file'
145
- message += 's' if files.size > 1
146
- UI.info "#{@msg_prefix} #{message.green}" unless @config[:silent]
147
- puts '| ' #spacing
148
- files.each do |file|
149
- path = destination_path file
150
- FileUtils.mkdir_p File.dirname(path)
151
- FileUtils.cp file, path
152
- puts '|' + " → ".green + path
153
- end
154
- puts '| ' #spacing
143
+ if files.size > 0
144
+ begin
145
+ message = 'copied file'
146
+ message += 's' if files.size > 1
147
+ UI.info "#{@msg_prefix} #{message.green}" unless @config[:silent]
148
+ puts '| ' #spacing
149
+ files.each do |file|
150
+ path = destination_path file
151
+ FileUtils.mkdir_p File.dirname(path)
152
+ FileUtils.cp file, path
153
+ puts '|' + " → ".green + path
154
+ end
155
+ puts '| ' #spacing
155
156
 
156
- rescue Exception => e
157
- UI.error "#{@msg_prefix} copy has failed" unless @config[:silent]
158
- UI.error e
159
- stop_server
160
- throw :task_has_failed
157
+ rescue Exception => e
158
+ UI.error "#{@msg_prefix} copy has failed" unless @config[:silent]
159
+ UI.error e
160
+ stop_server
161
+ throw :task_has_failed
162
+ end
163
+ true
161
164
  end
162
- true
163
165
  end
164
166
 
165
167
  def ignore_stitch_sources(files)
@@ -1,5 +1,5 @@
1
1
  module Guard
2
2
  class JekyllPlusVersion
3
- VERSION = "1.4.8"
3
+ VERSION = "1.4.9"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: guard-jekyll-plus
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.4.8
4
+ version: 1.4.9
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brandon Mathis