churned 0.1.1 → 0.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 44f32192a16cd016b5a440550061aae6abd47b4cdee47be38d919280b6b0eb5a
4
- data.tar.gz: 7de76f73f055cfe3411ecf47f1d751c9bf953ec60b175626fe85b388df2570fb
3
+ metadata.gz: a0abe825d0278d4075069f67e1197b02a3d6948029d12d180edc3e56d3e37c1c
4
+ data.tar.gz: c0946c4b5d246a647af357784d8ef9eadeff6e477472f07f13712fd97e7ddaa7
5
5
  SHA512:
6
- metadata.gz: eeec233ceb022c2616249c7ac0e5bdca0f9245ac9277d96f9aa76bc8179695eda23e16cd2c37a4e336bfb35d884d72c035ffaa5ea8e0380d4c9b1a41360f7a10
7
- data.tar.gz: ae0b8e0f8b964ccbd1da98afb4e918cc696bc323b9bd8aec764ea13fb3739ef4187d91cb9ed0c7d54aa485a1a559c4d7e093e1df92ebd79cc41b78a1a25be2f6
6
+ metadata.gz: 6449b52c2630e7420825b7ba32c59275e297f50d2940a00f5375e9078f72cf9afba49e9dda112f8cbb0a9fdad56dd9fda000a10811946c0ee899a1d5de510be2
7
+ data.tar.gz: 1da78d68aac0a79a41f0a1aa68f5d2e5beb94b28b87ee0f728fb2150c8008c8ae85d0c5323b139b0d69c4966c3a262b86f5f170e3e194aab3398cd3994f9c3d9
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- churned (0.1.1)
4
+ churned (0.1.2)
5
5
  activerecord (~> 6.1)
6
6
  pry
7
7
  sqlite3
@@ -32,14 +32,14 @@ module Churned
32
32
  command.run("git log --no-merges --pretty=format:'%H%n%ae' --numstat --since=1.years > .churned/hashes.txt")
33
33
 
34
34
  IO.read('.churned/hashes.txt').split("\n\n") do |description|
35
- lines = description.split
35
+ lines = description.split("\n")
36
36
 
37
37
  sha = lines.shift
38
38
  author = lines.shift
39
39
  commit = Commit.new(sha: sha, author: author)
40
40
 
41
- lines.each_slice(3) do |array|
42
- additions, deletions, pathname = array
41
+ lines.each do |numstat|
42
+ additions, deletions, pathname = numstat.split("\t")
43
43
  commit.file_changes.build(additions: additions, deletions: deletions, pathname: pathname)
44
44
  end
45
45
 
@@ -1,3 +1,3 @@
1
1
  module Churned
2
- VERSION = "0.1.1"
2
+ VERSION = "0.1.2"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: churned
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Alexandre Barret