bake-modernize 0.17.0 → 0.17.1

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
  SHA256:
3
- metadata.gz: '08439a38dc5093368958f4067f181d072c35631427bc7cdd4aaf0c01f92ac4b2'
4
- data.tar.gz: 18f75636b41aa9ccfd73f75279a7450390b9a350f66d0f5e60a09f92dcba3dac
3
+ metadata.gz: 8f189417bb977b5c61ff55ee0932bd71056bda27f34813df55ce6b6e7f539500
4
+ data.tar.gz: 494008b8417d4cbf9256e1fc7dd5b43f641c7ea1ada61bd4873f6cc4da3b6db8
5
5
  SHA512:
6
- metadata.gz: ce96787d866cb394a12d382ac3907b336f9e0e1c6cd72428710b05f5d1a3500543672ab37e21e10b9048d63869c47740a756f687357560c21ab37ef9f6b73f88
7
- data.tar.gz: 2f6bed57a621dd34e247af585947d7f13dbd9a468ab5335916335763455f44731b3f111ae7476ef51984c0ce2bc8e18ecdec6693df225c6a4180f8bbecdc74ee
6
+ metadata.gz: b1e384e012436cce00a5e0ebddbb25dabffcd4f8968e483ef372a32682396fb8f00f323a24825b69fe5fb51f7c2b237e5660c97a440fccc9b7fc42c5258db702
7
+ data.tar.gz: b05c4aac909f867b390000fa964ae616b8ddce0d8ca1d01a4473096cf1d4dbee0a12fc8c5947a73cd7d8ab4d27f85fa13c815b93603925f786825f25f5e74f06
checksums.yaml.gz.sig CHANGED
Binary file
@@ -154,8 +154,14 @@ module Bake
154
154
  def walk(repository, mailmap: nil, show: "HEAD")
155
155
  Rugged::Walker.walk(repository, show: show, sort: DEFAULT_SORT) do |commit|
156
156
  diff = commit.diff
157
- diff.find_similar!
158
-
157
+
158
+ # We relax the threshold for copy and rename detection because we want to detect files that have been moved and modified more generously.
159
+ diff.find_similar!(
160
+ rename_threshold: 25,
161
+ copy_threshold: 25,
162
+ ignore_whitespace: true,
163
+ )
164
+
159
165
  diff.each_delta do |delta|
160
166
  old_path = delta.old_file[:path]
161
167
  new_path = delta.new_file[:path]
@@ -164,6 +170,7 @@ module Bake
164
170
 
165
171
  if old_path != new_path
166
172
  # The file was moved, move copyright information too:
173
+ Console.logger.debug(self, "Moving #{old_path} to #{new_path}", similarity: delta.similarity)
167
174
  @paths[new_path].concat(@paths[old_path])
168
175
  end
169
176
 
@@ -5,6 +5,6 @@
5
5
 
6
6
  module Bake
7
7
  module Modernize
8
- VERSION = "0.17.0"
8
+ VERSION = "0.17.1"
9
9
  end
10
10
  end
data.tar.gz.sig CHANGED
Binary file
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: bake-modernize
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.17.0
4
+ version: 0.17.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Samuel Williams
metadata.gz.sig CHANGED
Binary file