gurney_client 0.2.1 → 0.2.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
  SHA256:
3
- metadata.gz: 3a6cb4778c8a278c1d91a6eb42c2757b841f830742f760e289d140ca0a8fa67a
4
- data.tar.gz: 995c92b582f0b49baa15042fadbc0bec9a3b3c2013ec0610a7f268785de60655
3
+ metadata.gz: 7c48954d1bfc52ad52a403cd36f679400cafbb4e0d5c6820dfa4ef7e2c3c555f
4
+ data.tar.gz: 288e682225abd4957e891755f90fc5fb276e9662ed6ddbef19ba3c6ed2e9acfc
5
5
  SHA512:
6
- metadata.gz: 5dd8b763b8ba1e0a79edaad6bca1ab43b40dc54cfbb1a16648dc020d5ffd2067d529fef5903144c54c12d3ca7018cf540b58ea34ea86e5d9c4a201fd8ee35db6
7
- data.tar.gz: 3c910d5fb6ce83e570bd267bcb4a31399c18096f0839090b611f5d3bb8049a58fb29930cd8319acc8e07a837d7355dedac248fa3f8f09cea785d8288734ffed7
6
+ metadata.gz: 688e1df6e72a084b038034e7c7d1d15e70c93744826220eee089eec34d3a78852e01d0abd1588a7152705f25a6e695b409b32197293f8bf34f079e36573bbed1
7
+ data.tar.gz: a93da5e3b0233730b119e3a29d8981be97b2a38a72ded8090ae019305f8c555cd5924b7d6a40902f7ee878d3878e19e0c94afceb6cda7c8b6c9e59b2fb58aef3
data/Gemfile.lock CHANGED
@@ -10,10 +10,13 @@ PATH
10
10
  GEM
11
11
  remote: https://rubygems.org/
12
12
  specs:
13
+ addressable (2.8.1)
14
+ public_suffix (>= 2.0.2, < 6.0)
13
15
  byebug (11.0.1)
14
16
  colorize (0.8.1)
15
17
  diff-lcs (1.3)
16
- git (1.7.0)
18
+ git (1.13.1)
19
+ addressable (~> 2.8)
17
20
  rchardet (~> 1.8)
18
21
  httparty (0.17.3)
19
22
  mime-types (~> 3.0)
@@ -22,6 +25,7 @@ GEM
22
25
  mime-types-data (~> 3.2015)
23
26
  mime-types-data (3.2020.0512)
24
27
  multi_xml (0.6.0)
28
+ public_suffix (5.0.1)
25
29
  rake (13.0.1)
26
30
  rchardet (1.8.0)
27
31
  rspec (3.9.0)
@@ -48,4 +52,4 @@ DEPENDENCIES
48
52
  rspec
49
53
 
50
54
  BUNDLED WITH
51
- 2.1.4
55
+ 2.2.27
data/gurney.gemspec CHANGED
@@ -11,6 +11,7 @@ Gem::Specification.new do |spec|
11
11
  spec.summary = 'Gurney is a small tool to extract yarn and RubyGems dependencies from project files and report them to a web api.'
12
12
  spec.homepage = "https://github.com/makandra/gurney"
13
13
  spec.license = "MIT"
14
+ spec.metadata = { 'rubygems_mfa_required' => 'true' }
14
15
 
15
16
  spec.files = `git ls-files`.split("\n").reject { |f| f.match(%r{^(test|spec|features|bin)/}) }
16
17
  spec.test_files = `git ls-files -- {test,spec,features}/*`.split("\n")
data/lib/gurney/cli.rb CHANGED
@@ -7,9 +7,9 @@ require 'fileutils'
7
7
 
8
8
  module Gurney
9
9
  class CLI
10
-
11
10
  HOOK_STDIN_REGEX = /(?<old>[0-9a-f]{40}) (?<new>[0-9a-f]{40}) refs\/heads\/(?<ref>\w+)/m
12
11
  CLIENT_HOOK_STDIN_REGEX = /refs\/heads\/(?<ref>\w+) (?<new>[0-9a-f]{40}) refs\/heads\/(?<remote_ref>\w+) (?<remote_sha>[0-9a-f]{40})/m
12
+ MAIN_BRANCHES = ['master', 'main'].freeze
13
13
 
14
14
  def self.run(cmd_parameter=[])
15
15
  options = Gurney::CLI::OptionParser.parse(cmd_parameter)
@@ -23,7 +23,10 @@ module Gurney
23
23
  end
24
24
  g = Git.open('.')
25
25
  end
26
- config_file = read_file(g, options.hook, 'master', options.config_file)
26
+ config_file = MAIN_BRANCHES.find do |branch|
27
+ file = read_file(g, options.hook, branch, options.config_file)
28
+ break file if file
29
+ end
27
30
  if !config_file && options.hook
28
31
  # dont run as a hook with no config
29
32
  exit 0
@@ -1,3 +1,3 @@
1
1
  module Gurney
2
- VERSION = "0.2.1"
2
+ VERSION = "0.2.2"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gurney_client
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.1
4
+ version: 0.2.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Martin Schaflitzl
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2020-06-24 00:00:00.000000000 Z
11
+ date: 2023-01-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: colorize
@@ -100,7 +100,8 @@ files:
100
100
  homepage: https://github.com/makandra/gurney
101
101
  licenses:
102
102
  - MIT
103
- metadata: {}
103
+ metadata:
104
+ rubygems_mfa_required: 'true'
104
105
  post_install_message:
105
106
  rdoc_options: []
106
107
  require_paths:
@@ -116,7 +117,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
116
117
  - !ruby/object:Gem::Version
117
118
  version: '0'
118
119
  requirements: []
119
- rubygems_version: 3.0.3
120
+ rubygems_version: 3.0.3.1
120
121
  signing_key:
121
122
  specification_version: 4
122
123
  summary: Gurney is a small tool to extract yarn and RubyGems dependencies from project