stitch-plus 1.0.6 → 1.0.7

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
- MTdiODc5ZWVmZDgxMDIzNTA0ZTJiMDNhM2YwZmNjNmEzNzYxNzUzZQ==
4
+ MDg0ZjM0ZWZkOTY0Y2ZkYjhhNzBhYTczOWU2ZjYyNmY2ODBkOTRmZg==
5
5
  data.tar.gz: !binary |-
6
- ZDg3OTU0ZTAyNmNlMTM2MDQzOTZiYzc2MDNmYjZiMjdhNTk5ZjBmNw==
6
+ NDVmZDA0ZGNhOTYzMDFiNWM1YjlkZThjZDY5NmRiYmZlNzY1NDc2Yw==
7
7
  !binary "U0hBNTEy":
8
8
  metadata.gz: !binary |-
9
- ZGJhNWIwNjJhOWZjM2RlYzNiNWY1NmE0NTIzMDQxMTk3NzY4NDkzOTgzZGY2
10
- ZmIxNDQ1OThiY2Y0Y2Y3NmJjZTMwYmFkZDAwYmIyYzVkZTQ0YzFlMzc0Zjlh
11
- MmJkNTIyMDI4MGE2M2JlYTJlZmU1N2M4MGNiYjRkMGMzY2U2Yzc=
9
+ ZGZiOTkyMTlmZmI4NTI1NDFlMzkxZTI2OGY0ODgzYzM2N2MzMThjZDYxNmZh
10
+ ZTMzZTk5YTAzYWIyOTMxMzgyYjRjZDA0ZmQ1Mzk3OTc3MjdhNzA3MzdhOGYx
11
+ MjdlYzdkZjEyYzQ4ZjE2NmZmODBmMDZiYjJkMTUxZGE4NWRiMDc=
12
12
  data.tar.gz: !binary |-
13
- MWJhMGUyZjQwNTQ4ODVhY2E5YzE3NjJjZjNiZWEwYjk5OGYzYjEwMWVjNzg4
14
- NDhlZWQ4YmYxOWE5MmI3MzEzNmZjYTEyNGQ0ZmYyZGZhYjBjZTRkYjE5ODY2
15
- OGQwMTZmNTJiNDhiYjQ3NjYxOTI1YWZjN2FjZmYzYjFjNGQ5Yzc=
13
+ ZjgwMTQzMmE5ZWE3OGU3Y2JlNjQ4NTg3MzRmYTk3ZGI0ZTUyMjZjNzAxMGJl
14
+ YjU0MzVmNTA0MDlhNWRkNjVlMDQyYzM0M2FhMzk2MWE1YmE2NTdmZmJiMjI5
15
+ OTMzZmFlOTlmNGViMzk2ZDJhMzExY2JhZDNjM2QxMzYzZmZjZWM=
data/CHANGELOG.md CHANGED
@@ -25,3 +25,6 @@
25
25
  ## 1.0.6
26
26
  - [instance].deleted returns an array of deleted files if stitch cleaned up files when writing.
27
27
  - performance improvements for cleanup method.
28
+
29
+ ## 1.0.7
30
+ - Paths appearing in messages will now start from the current directory
data/README.md CHANGED
@@ -40,6 +40,9 @@ s.write
40
40
  # Get the path to the most recently written file (or nil)
41
41
  s.last_write #> javascripts/app-f1408932717b4b16eb97969d34961213.js
42
42
 
43
+ # Return an array of files deleted by cleanup
44
+ s.deleted
45
+
43
46
  # Return the array of javascripts to be compiled
44
47
  s.all_files
45
48
 
data/lib/stitch-plus.rb CHANGED
@@ -88,12 +88,12 @@ class StitchPlus
88
88
  js = "/* Build fingerprint: #{@fingerprint} */\n" + compile
89
89
 
90
90
  if has_fingerprint(@file, @fingerprint)
91
- info "Stitch " + "identical ".green + @file
91
+ info "Stitch " + "identical ".green + @file.sub(Dir.pwd, '')
92
92
  reset_options if options
93
93
  true
94
94
  else
95
95
  begin
96
- write_msg = (File.exists?(@file) ? "overwrite " : "created ").yellow + @file
96
+ write_msg = (File.exists?(@file) ? "overwrite " : "created ").yellow + @file.sub(Dir.pwd, '')
97
97
  cleanup(@file) if @options[:cleanup]
98
98
 
99
99
  File.open(@file, 'w') { |f| f.write js }
@@ -101,7 +101,7 @@ class StitchPlus
101
101
  info "Stitch " + write_msg
102
102
  true
103
103
  rescue StandardError => e
104
- error "Stitch failed to write #{@file}".red
104
+ error "Stitch failed to write #{@file.sub(Dir.pwd, '')}".red
105
105
  error e
106
106
  reset_options if options
107
107
  false
@@ -159,7 +159,7 @@ class StitchPlus
159
159
  if File.basename(item) != File.basename(file)
160
160
  info "Stitch " + "deleted ".red + item
161
161
  FileUtils.rm(item)
162
- @deleted << item
162
+ @deleted << item.sub(Dir.pwd, '')
163
163
  end
164
164
  end
165
165
  end
@@ -1,3 +1,3 @@
1
1
  module StitchPlusVersion
2
- VERSION = "1.0.6"
2
+ VERSION = "1.0.7"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: stitch-plus
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.6
4
+ version: 1.0.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brandon Mathis