safedep 0.3.2 → 0.4.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/.rubocop.yml +20 -36
- data/.travis.yml +7 -7
- data/Gemfile +4 -4
- data/README.md +4 -5
- data/Rakefile +1 -1
- data/lib/safedep/policy/sem_ver.rb +1 -1
- data/lib/safedep/runner.rb +3 -3
- data/lib/safedep/version.rb +2 -2
- data/safedep.gemspec +2 -3
- data/spec/.rubocop.yml +4 -1
- data/spec/support/file_helper.rb +1 -1
- metadata +7 -14
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: adbefe2e5fbb56a878cb340680ed0c59cc3b2f754ad37b248009bc67676f1c3c
|
4
|
+
data.tar.gz: 8731183111822d0696f85e0ab25224aba20c6b40e558e91821dba1a08a9298f4
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b24275e230a76bf02e1caa3d5b4435ca49ce6e9bc4d8d1c5cdf3fd3d727b909b006efabdcaa794afa72160d0b34723121404603b2b98622d2140ec4c769f6676
|
7
|
+
data.tar.gz: 734a7709efc25467099e55b92101460befec1f7bf5db4c761e4e9e06f4561a137386fd97c6c9e6f04484a71a60501bb6803609fb1db6ff5ac5bd1d2f9975cd0c
|
data/.rubocop.yml
CHANGED
@@ -1,4 +1,3 @@
|
|
1
|
-
|
2
1
|
AllCops:
|
3
2
|
Include:
|
4
3
|
- '*.gemspec'
|
@@ -8,54 +7,39 @@ AllCops:
|
|
8
7
|
Exclude:
|
9
8
|
- 'vendor/**/*'
|
10
9
|
|
11
|
-
|
10
|
+
Layout/AlignHash:
|
11
|
+
EnforcedHashRocketStyle: table
|
12
|
+
EnforcedColonStyle: separator
|
13
|
+
|
14
|
+
Metrics/AbcSize:
|
15
|
+
Max: 20
|
16
|
+
|
17
|
+
Metrics/BlockLength:
|
18
|
+
Exclude:
|
19
|
+
- 'spec/**/*'
|
20
|
+
|
21
|
+
Metrics/LineLength:
|
12
22
|
Max: 100
|
13
23
|
|
14
|
-
MethodLength:
|
24
|
+
Metrics/MethodLength:
|
15
25
|
Max: 15
|
16
26
|
|
17
|
-
|
18
|
-
|
27
|
+
Naming/HeredocDelimiterNaming:
|
28
|
+
Enabled: false
|
19
29
|
|
20
|
-
RegexpLiteral:
|
30
|
+
Style/RegexpLiteral:
|
21
31
|
Exclude:
|
22
32
|
- '*.gemspec'
|
23
33
|
- 'Guardfile'
|
24
34
|
|
25
|
-
|
35
|
+
Style/Documentation:
|
26
36
|
Enabled: false
|
27
37
|
|
28
|
-
|
29
|
-
# Alignment of entries using hash rocket as separator. Valid values are:
|
30
|
-
#
|
31
|
-
# key - left alignment of keys
|
32
|
-
# 'a' => 2
|
33
|
-
# 'bb' => 3
|
34
|
-
# separator - alignment of hash rockets, keys are right aligned
|
35
|
-
# 'a' => 2
|
36
|
-
# 'bb' => 3
|
37
|
-
# table - left alignment of keys, hash rockets, and values
|
38
|
-
# 'a' => 2
|
39
|
-
# 'bb' => 3
|
40
|
-
EnforcedHashRocketStyle: table
|
41
|
-
# Alignment of entries using colon as separator. Valid values are:
|
42
|
-
#
|
43
|
-
# key - left alignment of keys
|
44
|
-
# a: 0
|
45
|
-
# bb: 1
|
46
|
-
# separator - alignment of colons, keys are right aligned
|
47
|
-
# a: 0
|
48
|
-
# bb: 1
|
49
|
-
# table - left alignment of keys and values
|
50
|
-
# a: 0
|
51
|
-
# bb: 1
|
52
|
-
EnforcedColonStyle: separator
|
53
|
-
|
54
|
-
GuardClause:
|
38
|
+
Style/EmptyElse:
|
55
39
|
Enabled: false
|
56
40
|
|
57
|
-
|
41
|
+
Style/GuardClause:
|
58
42
|
Enabled: false
|
59
43
|
|
60
|
-
SingleLineBlockParams:
|
44
|
+
Style/SingleLineBlockParams:
|
61
45
|
Enabled: false
|
data/.travis.yml
CHANGED
@@ -1,11 +1,11 @@
|
|
1
1
|
language: ruby
|
2
2
|
rvm:
|
3
|
-
-
|
4
|
-
- 2.
|
5
|
-
- 2.
|
6
|
-
- 2.
|
7
|
-
-
|
8
|
-
- jruby-19mode
|
9
|
-
script: bundle exec rake ci
|
3
|
+
- 2.2.9
|
4
|
+
- 2.3.6
|
5
|
+
- 2.4.3
|
6
|
+
- 2.5.0
|
7
|
+
- jruby-9.1.15.0
|
10
8
|
sudo: false
|
11
9
|
cache: bundler
|
10
|
+
before_install: gem update --system
|
11
|
+
script: bundle exec rake ci
|
data/Gemfile
CHANGED
@@ -3,17 +3,17 @@ source 'https://rubygems.org'
|
|
3
3
|
gemspec
|
4
4
|
|
5
5
|
group :development, :test do
|
6
|
-
gem 'rake', '~> 10.4'
|
7
|
-
gem 'rspec', '~> 3.1'
|
8
|
-
gem 'rubocop', '~> 0.28'
|
9
6
|
gem 'powerpack', '~> 0.0'
|
7
|
+
gem 'rake', '~> 11.1'
|
8
|
+
gem 'rspec', '~> 3.1'
|
9
|
+
gem 'rubocop', '~> 0.52'
|
10
10
|
gem 'simplecov', '~> 0.9'
|
11
11
|
end
|
12
12
|
|
13
13
|
group :development do
|
14
|
+
gem 'fuubar', '~> 2.0'
|
14
15
|
gem 'guard-rspec', '~> 4.5'
|
15
16
|
gem 'guard-rubocop', '~> 1.2'
|
16
|
-
gem 'fuubar', '~> 2.0'
|
17
17
|
gem 'ruby_gntp', '~> 0.3'
|
18
18
|
end
|
19
19
|
|
data/README.md
CHANGED
@@ -1,8 +1,7 @@
|
|
1
|
-
[![Gem Version](
|
2
|
-
[![Dependency Status](http://img.shields.io/gemnasium/yujinakayama/safedep.svg?style=flat)](https://gemnasium.com/yujinakayama/safedep)
|
1
|
+
[![Gem Version](https://badge.fury.io/rb/safedep.svg)](http://badge.fury.io/rb/safedep)
|
3
2
|
[![Build Status](https://travis-ci.org/yujinakayama/safedep.svg?branch=master&style=flat)](https://travis-ci.org/yujinakayama/safedep)
|
4
|
-
[![Coverage Status](
|
5
|
-
[![Code Climate](https://
|
3
|
+
[![Coverage Status](https://coveralls.io/repos/yujinakayama/safedep/badge.svg?branch=master&service=github)](https://coveralls.io/github/yujinakayama/safedep?branch=master)
|
4
|
+
[![Code Climate](https://codeclimate.com/github/yujinakayama/safedep/badges/gpa.svg)](https://codeclimate.com/github/yujinakayama/safedep)
|
6
5
|
|
7
6
|
# Safedep
|
8
7
|
|
@@ -91,7 +90,7 @@ $ safedep --without development,test
|
|
91
90
|
|
92
91
|
## Compatibility
|
93
92
|
|
94
|
-
Tested on MRI
|
93
|
+
Tested on MRI 2.2, 2.3, 2.4, 2.5 and JRuby 9000.
|
95
94
|
|
96
95
|
## License
|
97
96
|
|
data/Rakefile
CHANGED
@@ -32,7 +32,7 @@ module Safedep
|
|
32
32
|
def decompose_version
|
33
33
|
elements = version.to_s.split('.')
|
34
34
|
|
35
|
-
[
|
35
|
+
%i[major minor patch].each do |role|
|
36
36
|
if elements.first && elements.first.match(/^\d+$/)
|
37
37
|
instance_variable_set("@#{role}", elements.shift)
|
38
38
|
else
|
data/lib/safedep/runner.rb
CHANGED
@@ -24,7 +24,7 @@ module Safedep
|
|
24
24
|
lockfile_dep = gemfile_lock.find_dependency(dep.name)
|
25
25
|
|
26
26
|
unless lockfile_dep
|
27
|
-
|
27
|
+
raise Error, "#{dep.name.inspect} definition is not found in #{gemfile_lock.path}. " \
|
28
28
|
'Please run `bundle install`.'
|
29
29
|
end
|
30
30
|
|
@@ -72,13 +72,13 @@ module Safedep
|
|
72
72
|
return if File.exist?(path)
|
73
73
|
message = "#{path} is not found."
|
74
74
|
message << ' ' + additional_message if additional_message
|
75
|
-
|
75
|
+
raise Error, message
|
76
76
|
end
|
77
77
|
|
78
78
|
def should_ignore?(dependency)
|
79
79
|
return true unless dependency.version_specifiers.empty?
|
80
80
|
return true unless (dependency.groups & configuration.skipped_groups).empty?
|
81
|
-
[
|
81
|
+
%i[git github path].any? { |key| dependency.options[key] }
|
82
82
|
end
|
83
83
|
|
84
84
|
def version_specifiers(version)
|
data/lib/safedep/version.rb
CHANGED
data/safedep.gemspec
CHANGED
@@ -1,4 +1,3 @@
|
|
1
|
-
# coding: utf-8
|
2
1
|
lib = File.expand_path('../lib', __FILE__)
|
3
2
|
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
4
3
|
require 'safedep/version'
|
@@ -19,6 +18,6 @@ Gem::Specification.new do |spec|
|
|
19
18
|
spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
|
20
19
|
spec.require_paths = ['lib']
|
21
20
|
|
22
|
-
spec.add_runtime_dependency 'bundler', '
|
23
|
-
spec.add_runtime_dependency 'gemologist', '>= 0.
|
21
|
+
spec.add_runtime_dependency 'bundler', '>= 1.7'
|
22
|
+
spec.add_runtime_dependency 'gemologist', '>= 0.3'
|
24
23
|
end
|
data/spec/.rubocop.yml
CHANGED
@@ -6,7 +6,7 @@ LineLength:
|
|
6
6
|
Max: 120
|
7
7
|
|
8
8
|
# raise_error matcher always requires {} form block.
|
9
|
-
|
9
|
+
BlockDelimiters:
|
10
10
|
Enabled: false
|
11
11
|
|
12
12
|
# Sometimes block alignment does not suit RSpec syntax.
|
@@ -16,3 +16,6 @@ BlockAlignment:
|
|
16
16
|
# Suppress offences for namespace classes only with #describe.
|
17
17
|
ClassLength:
|
18
18
|
Enabled: false
|
19
|
+
|
20
|
+
ModuleLength:
|
21
|
+
Enabled: false
|
data/spec/support/file_helper.rb
CHANGED
metadata
CHANGED
@@ -1,27 +1,27 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: safedep
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.4.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Yuji Nakayama
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2019-06-05 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
15
15
|
requirement: !ruby/object:Gem::Requirement
|
16
16
|
requirements:
|
17
|
-
- - "
|
17
|
+
- - ">="
|
18
18
|
- !ruby/object:Gem::Version
|
19
19
|
version: '1.7'
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
|
-
- - "
|
24
|
+
- - ">="
|
25
25
|
- !ruby/object:Gem::Version
|
26
26
|
version: '1.7'
|
27
27
|
- !ruby/object:Gem::Dependency
|
@@ -30,20 +30,14 @@ dependencies:
|
|
30
30
|
requirements:
|
31
31
|
- - ">="
|
32
32
|
- !ruby/object:Gem::Version
|
33
|
-
version: 0.
|
34
|
-
- - "<"
|
35
|
-
- !ruby/object:Gem::Version
|
36
|
-
version: '1.0'
|
33
|
+
version: '0.3'
|
37
34
|
type: :runtime
|
38
35
|
prerelease: false
|
39
36
|
version_requirements: !ruby/object:Gem::Requirement
|
40
37
|
requirements:
|
41
38
|
- - ">="
|
42
39
|
- !ruby/object:Gem::Version
|
43
|
-
version: 0.
|
44
|
-
- - "<"
|
45
|
-
- !ruby/object:Gem::Version
|
46
|
-
version: '1.0'
|
40
|
+
version: '0.3'
|
47
41
|
description: Make your Gemfile safe by adding dependency version specifiers automatically.
|
48
42
|
email:
|
49
43
|
- nkymyj@gmail.com
|
@@ -98,8 +92,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
98
92
|
- !ruby/object:Gem::Version
|
99
93
|
version: '0'
|
100
94
|
requirements: []
|
101
|
-
|
102
|
-
rubygems_version: 2.4.8
|
95
|
+
rubygems_version: 3.0.3
|
103
96
|
signing_key:
|
104
97
|
specification_version: 4
|
105
98
|
summary: Make your Gemfile safe by adding dependency version specifiers automatically.
|