unparser 0.4.3 → 0.4.8

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: 27b8023ba4879d4fb484914a38e3bf2515275744a3965c5be4e050669fed819c
4
- data.tar.gz: '0958f06e01392248f103326228a6c3ed40ff55d0f77532faad27aaba38f8b604'
3
+ metadata.gz: 0dee214bf2371dbf22755d995f36fd96cd1a93b2a2bf846382525c8d41e61ecf
4
+ data.tar.gz: 6ed35f024038b383369479b1ff851a7a2cc207b248a2340f218e452b2dded583
5
5
  SHA512:
6
- metadata.gz: b6ebe89713f227671ffdc0cac31cc4de547ebb8dfdb93adc8224373ef2b304706d89b83dc87df40b93cadcf30af689f93970b949116862f8f294336219569e60
7
- data.tar.gz: a856b12aed96ddba957eadc62d0afcea47f563e6ec2fe0da47b68e7b65ae712f8e31ceeeb42644740dad05815273d55fe850c09e0fdcc179a21969bb9d77395f
6
+ metadata.gz: 534bc06ed25ef60d1a111fc301b75bb97632cb988498cd48914a6cd8bef7d13710f24674ee9166c05f2f01d53cc7e2dfd13289c27d0789ade5a45b32d4a4e9a2
7
+ data.tar.gz: f84a1c3efd6f6c2d77990ac57b266ca1e50b45dbd35202b294972cb9b094c6dfa4e7026986f0ab7ca0c82726f6deac77db9d7f5b6ba940f6203795649f9ee1eb
@@ -0,0 +1,90 @@
1
+ name: CI
2
+
3
+ on: push
4
+
5
+ jobs:
6
+ base:
7
+ name: Base steps
8
+ runs-on: ubuntu-latest
9
+ steps:
10
+ - uses: actions/checkout@v2
11
+ - name: Check Whitespace
12
+ run: git diff --check -- HEAD~1
13
+ ruby-unit-spec:
14
+ name: Unit Specs
15
+ runs-on: ${{ matrix.os }}
16
+ timeout-minutes: 5
17
+ strategy:
18
+ fail-fast: false
19
+ matrix:
20
+ ruby: ['2.6']
21
+ os: [ubuntu-latest]
22
+ steps:
23
+ - uses: actions/checkout@v2
24
+ - uses: actions/setup-ruby@v1
25
+ with:
26
+ ruby-version: ${{ matrix.ruby }}
27
+ - run: |
28
+ gem install bundler
29
+ bundle install
30
+ - run: bundle exec rspec spec/unit
31
+ ruby-integration-spec:
32
+ name: Integration Specs
33
+ runs-on: ${{ matrix.os }}
34
+ timeout-minutes: 5
35
+ strategy:
36
+ fail-fast: false
37
+ matrix:
38
+ ruby: ['2.6']
39
+ os: [ubuntu-latest]
40
+ steps:
41
+ - uses: actions/checkout@v2
42
+ - uses: actions/setup-ruby@v1
43
+ with:
44
+ ruby-version: ${{ matrix.ruby }}
45
+ - run: |
46
+ gem install bundler
47
+ bundle install
48
+ - run: bundle exec rspec spec/integration
49
+ ruby-mutant:
50
+ name: Mutation coverage
51
+ runs-on: ${{ matrix.os }}
52
+ timeout-minutes: 5
53
+ strategy:
54
+ fail-fast: false
55
+ matrix:
56
+ ruby: ['2.6']
57
+ os: [ubuntu-latest]
58
+ steps:
59
+ - uses: actions/checkout@v2
60
+ with:
61
+ fetch-depth: 0
62
+ - uses: actions/setup-ruby@v1
63
+ with:
64
+ ruby-version: ${{ matrix.ruby }}
65
+ - run: |
66
+ gem install bundler
67
+ bundle install
68
+ - run: |
69
+ bundle exec mutant \
70
+ --since HEAD~1 \
71
+ --zombie \
72
+ --ignore-subject 'Unparser::CLI*' \
73
+ --ignore-subject 'Unparser::Validation.from_string' \
74
+ -- 'Unparser*'
75
+ ruby-rubocop:
76
+ name: Rubocop
77
+ runs-on: ${{ matrix.os }}
78
+ timeout-minutes: 5
79
+ strategy:
80
+ fail-fast: false
81
+ matrix:
82
+ ruby: ['2.6']
83
+ os: [ubuntu-latest]
84
+ steps:
85
+ - uses: actions/checkout@v2
86
+ - uses: actions/setup-ruby@v1
87
+ with:
88
+ ruby-version: ${{ matrix.ruby }}
89
+ - run: bundle install
90
+ - run: bundle exec rubocop
@@ -1,9 +1,126 @@
1
1
  AllCops:
2
2
  Include:
3
+ - 'lib/unparser.rb'
4
+ - 'lib/unparser/**/*.rb'
5
+ - '**/*.rake'
3
6
  - 'Gemfile'
7
+ - 'Gemfile.triage'
8
+
9
+ # Avoid parameter lists longer than five parameters.
10
+ ParameterLists:
11
+ Max: 3
12
+ CountKeywordArgs: true
13
+
14
+ MethodLength:
15
+ CountComments: false
16
+ Max: 17
17
+
18
+ AbcSize:
19
+ Max: 18
20
+
21
+ # Avoid more than `Max` levels of nesting.
22
+ BlockNesting:
23
+ Max: 3
24
+
25
+ # Align with the style guide.
26
+ CollectionMethods:
27
+ PreferredMethods:
28
+ collect: 'map'
29
+ inject: 'reduce'
30
+ find: 'detect'
31
+ find_all: 'select'
32
+
33
+ # Limit line length
34
+ LineLength:
35
+ Max: 113 # TODO: lower to 79 once the rubocop branch in shared/Gemfile is removed
36
+
37
+ ClassLength:
38
+ Max: 204
39
+
40
+ # Prefer modifiers and explicit if statements over returning early for small methods
41
+ GuardClause:
42
+ Enabled: false
43
+
44
+ Metrics/BlockLength:
4
45
  Exclude:
5
- - 'Gemfile.devtools'
6
- - 'vendor/**/*'
7
- - 'benchmarks/**/*'
8
- - 'tmp/**/*'
9
- TargetRubyVersion: 2.5
46
+ # Ignore RSpec DSL
47
+ - spec/**/*
48
+
49
+ # Flags freezes for singletons that could still be mutated like Regexps
50
+ RedundantFreeze:
51
+ Enabled: false
52
+
53
+ # Allow Fixnum and Bignum. This Gem supports versions before 2.4
54
+ UnifiedInteger:
55
+ Enabled: false
56
+
57
+ # Disabled because of indenting with private keyword in class bodies.
58
+ IndentationWidth:
59
+ Enabled: false
60
+
61
+ # I like raise more
62
+ SignalException:
63
+ Enabled: false
64
+
65
+ # False positive in unparser source
66
+ OneLineConditional:
67
+ Enabled: false
68
+
69
+ Documentation:
70
+ Enabled: false
71
+
72
+ # Disable documentation checking until a class needs to be documented once
73
+ Documentation:
74
+ Enabled: false
75
+
76
+ # Do not favor modifier if/unless usage when you have a single-line body
77
+ IfUnlessModifier:
78
+ Enabled: false
79
+
80
+ # Allow case equality operator (in limited use within the specs)
81
+ CaseEquality:
82
+ Enabled: false
83
+
84
+ # Constants do not always have to use SCREAMING_SNAKE_CASE
85
+ ConstantName:
86
+ Enabled: false
87
+
88
+ # Not all trivial readers/writers can be defined with attr_* methods
89
+ TrivialAccessors:
90
+ Enabled: false
91
+
92
+ # I like to have an empty line before closing the currently opened body
93
+ EmptyLinesAroundBlockBody:
94
+ Enabled: false
95
+
96
+ EmptyLinesAroundClassBody:
97
+ Enabled: false
98
+
99
+ EmptyLinesAroundModuleBody:
100
+ Enabled: false
101
+
102
+ # I like my style more
103
+ AccessModifierIndentation:
104
+ Enabled: false
105
+
106
+ Style/CommentedKeyword:
107
+ Enabled: false
108
+
109
+ Style/MixinGrouping:
110
+ Enabled: false
111
+
112
+ Lint/BooleanSymbol:
113
+ Enabled: false
114
+
115
+ Style/AccessModifierDeclarations:
116
+ Enabled: false
117
+
118
+ Layout/HashAlignment:
119
+ EnforcedColonStyle: table
120
+ EnforcedHashRocketStyle: table
121
+
122
+ Naming/RescuedExceptionsVariableName:
123
+ Enabled: false
124
+
125
+ Layout/MultilineMethodCallIndentation:
126
+ Enabled: false
@@ -1,3 +1,27 @@
1
+ # v0.4.8 2020-05-25
2
+
3
+ * Change to specific node type when unparser fails on an unknown node type: [#150](https://github.com/mbj/unparser/pull/150)
4
+ * Significantly improve verifier (only useful for debugging)
5
+ * Add `Unparser::Color` module for colorized source diffs
6
+
7
+ # v0.4.7 2020-01-03
8
+
9
+ * Add support for endless ranges
10
+ * Change to allow parser 2.7, even while syntax is not yet supported.
11
+ This reduces downstream complexity.
12
+
13
+ # v0.4.6 2020-01-02
14
+
15
+ * Upgrades to allow parser dependency to ~> 2.6.5
16
+
17
+ # v0.4.5 2019-05-10
18
+
19
+ * Bump parser dependency to ~> 2.6.3
20
+
21
+ # v0.4.4 2019-03-27
22
+
23
+ * Bump parser dependency to ~> 2.6.2
24
+
1
25
  # v0.4.3 2019-02-24
2
26
 
3
27
  * Bump parser dependency to ~> 2.6.0
data/Gemfile CHANGED
@@ -4,8 +4,6 @@ source 'https://rubygems.org'
4
4
 
5
5
  gemspec
6
6
 
7
- gem(
8
- 'mutant',
9
- branch: 'upgrade/dependencies',
10
- git: 'https://github.com/mbj/mutant.git'
11
- )
7
+ source 'https://oss:Px2ENN7S91OmWaD5G7MIQJi1dmtmYrEh@gem.mutant.dev' do
8
+ gem 'mutant-license'
9
+ end
@@ -1,40 +1,20 @@
1
- GIT
2
- remote: https://github.com/mbj/mutant.git
3
- revision: d1d1993427ec01cc9b57a3a87ce23a7c41456a39
4
- branch: upgrade/dependencies
5
- specs:
6
- mutant (0.8.25)
7
- abstract_type (~> 0.0.7)
8
- adamantium (~> 0.2.0)
9
- anima (~> 0.3.1)
10
- ast (~> 2.2)
11
- concord (~> 0.1.5)
12
- diff-lcs (~> 1.3)
13
- equalizer (~> 0.0.9)
14
- ice_nine (~> 0.11.1)
15
- memoizable (~> 0.4.2)
16
- morpher (~> 0.2.6)
17
- parser (~> 2.6.0)
18
- procto (~> 0.0.2)
19
- unparser (~> 0.4.2)
20
- mutant-rspec (0.8.25)
21
- mutant (~> 0.8.25)
22
- rspec-core (>= 3.8.0, < 4.0.0)
23
-
24
1
  PATH
25
2
  remote: .
26
3
  specs:
27
- unparser (0.4.2)
4
+ unparser (0.4.7)
28
5
  abstract_type (~> 0.0.7)
29
6
  adamantium (~> 0.2.0)
7
+ anima (~> 0.3.1)
30
8
  concord (~> 0.1.5)
31
9
  diff-lcs (~> 1.3)
32
10
  equalizer (~> 0.0.9)
33
- parser (~> 2.6.0)
11
+ mprelude (~> 0.1.0)
12
+ parser (>= 2.6.5)
34
13
  procto (~> 0.0.2)
35
14
 
36
15
  GEM
37
16
  remote: https://rubygems.org/
17
+ remote: https://oss:Px2ENN7S91OmWaD5G7MIQJi1dmtmYrEh@gem.mutant.dev/
38
18
  specs:
39
19
  abstract_type (0.0.7)
40
20
  adamantium (0.2.0)
@@ -44,134 +24,87 @@ GEM
44
24
  abstract_type (~> 0.0.7)
45
25
  adamantium (~> 0.2)
46
26
  equalizer (~> 0.0.11)
47
- ast (2.4.0)
48
- axiom-types (0.1.1)
49
- descendants_tracker (~> 0.0.4)
50
- ice_nine (~> 0.11.0)
51
- thread_safe (~> 0.3, >= 0.3.1)
52
- codeclimate-engine-rb (0.4.1)
53
- virtus (~> 1.0)
54
- coercible (1.0.0)
55
- descendants_tracker (~> 0.0.1)
27
+ ast (2.4.1)
56
28
  concord (0.1.5)
57
29
  adamantium (~> 0.2.0)
58
30
  equalizer (~> 0.0.9)
59
- descendants_tracker (0.0.4)
60
- thread_safe (~> 0.3, >= 0.3.1)
61
- devtools (0.1.23)
62
- abstract_type (~> 0.0.7)
63
- adamantium (~> 0.2.0)
64
- anima (~> 0.3.0)
65
- concord (~> 0.1.5)
66
- flay (~> 2.12.0)
67
- flog (~> 4.6.2)
68
- mutant (~> 0.8.24)
69
- mutant-rspec (~> 0.8.24)
70
- procto (~> 0.0.3)
71
- rake (~> 12.3.0)
72
- reek (~> 5.3.0)
73
- rspec (~> 3.8.0)
74
- rspec-core (~> 3.8.0)
75
- rspec-its (~> 1.2.0)
76
- rubocop (~> 0.61.1)
77
- simplecov (~> 0.16.1)
78
- yard (~> 0.9.16)
79
- yardstick (~> 0.9.9)
80
31
  diff-lcs (1.3)
81
- docile (1.3.1)
82
32
  equalizer (0.0.11)
83
- erubis (2.7.0)
84
- flay (2.12.0)
85
- erubis (~> 2.7.0)
86
- path_expander (~> 1.0)
87
- ruby_parser (~> 3.0)
88
- sexp_processor (~> 4.0)
89
- flog (4.6.2)
90
- path_expander (~> 1.0)
91
- ruby_parser (~> 3.1, > 3.1.0)
92
- sexp_processor (~> 4.8)
93
33
  ice_nine (0.11.2)
94
- jaro_winkler (1.5.2)
95
- json (2.2.0)
96
- kwalify (0.7.2)
34
+ jaro_winkler (1.5.4)
97
35
  memoizable (0.4.2)
98
36
  thread_safe (~> 0.3, >= 0.3.1)
99
- morpher (0.2.6)
37
+ mprelude (0.1.0)
38
+ abstract_type (~> 0.0.7)
39
+ adamantium (~> 0.2.0)
40
+ concord (~> 0.1.5)
41
+ equalizer (~> 0.0.9)
42
+ ice_nine (~> 0.11.1)
43
+ procto (~> 0.0.2)
44
+ mutant (0.9.9)
100
45
  abstract_type (~> 0.0.7)
101
46
  adamantium (~> 0.2.0)
102
- anima (~> 0.3.0)
47
+ anima (~> 0.3.1)
103
48
  ast (~> 2.2)
104
49
  concord (~> 0.1.5)
50
+ diff-lcs (= 1.3)
105
51
  equalizer (~> 0.0.9)
106
- ice_nine (~> 0.11.0)
52
+ ice_nine (~> 0.11.1)
53
+ memoizable (~> 0.4.2)
54
+ mprelude (~> 0.1.0)
55
+ parser (~> 2.7.1)
107
56
  procto (~> 0.0.2)
108
- parallel (1.13.0)
109
- parser (2.6.0.0)
110
- ast (~> 2.4.0)
111
- path_expander (1.0.3)
112
- powerpack (0.1.2)
57
+ unparser (~> 0.4.6)
58
+ variable (~> 0.0.1)
59
+ mutant-license (0.1.0)
60
+ mutant-rspec (0.9.9)
61
+ mutant (~> 0.9.9)
62
+ rspec-core (>= 3.8.0, < 4.0.0)
63
+ parallel (1.19.2)
64
+ parser (2.7.1.4)
65
+ ast (~> 2.4.1)
113
66
  procto (0.0.3)
114
- psych (3.1.0)
115
67
  rainbow (3.0.0)
116
- rake (12.3.2)
117
- reek (5.3.1)
118
- codeclimate-engine-rb (~> 0.4.0)
119
- kwalify (~> 0.7.0)
120
- parser (>= 2.5.0.0, < 2.7, != 2.5.1.1)
121
- psych (~> 3.1.0)
122
- rainbow (>= 2.0, < 4.0)
123
- rspec (3.8.0)
124
- rspec-core (~> 3.8.0)
125
- rspec-expectations (~> 3.8.0)
126
- rspec-mocks (~> 3.8.0)
127
- rspec-core (3.8.0)
128
- rspec-support (~> 3.8.0)
129
- rspec-expectations (3.8.2)
68
+ rspec (3.9.0)
69
+ rspec-core (~> 3.9.0)
70
+ rspec-expectations (~> 3.9.0)
71
+ rspec-mocks (~> 3.9.0)
72
+ rspec-core (3.9.2)
73
+ rspec-support (~> 3.9.3)
74
+ rspec-expectations (3.9.2)
130
75
  diff-lcs (>= 1.2.0, < 2.0)
131
- rspec-support (~> 3.8.0)
76
+ rspec-support (~> 3.9.0)
132
77
  rspec-its (1.2.0)
133
78
  rspec-core (>= 3.0.0)
134
79
  rspec-expectations (>= 3.0.0)
135
- rspec-mocks (3.8.0)
80
+ rspec-mocks (3.9.1)
136
81
  diff-lcs (>= 1.2.0, < 2.0)
137
- rspec-support (~> 3.8.0)
138
- rspec-support (3.8.0)
139
- rubocop (0.61.1)
82
+ rspec-support (~> 3.9.0)
83
+ rspec-support (3.9.3)
84
+ rubocop (0.79.0)
140
85
  jaro_winkler (~> 1.5.1)
141
86
  parallel (~> 1.10)
142
- parser (>= 2.5, != 2.5.1.1)
143
- powerpack (~> 0.1)
87
+ parser (>= 2.7.0.1)
144
88
  rainbow (>= 2.2.2, < 4.0)
145
89
  ruby-progressbar (~> 1.7)
146
- unicode-display_width (~> 1.4.0)
147
- ruby-progressbar (1.10.0)
148
- ruby_parser (3.12.0)
149
- sexp_processor (~> 4.9)
150
- sexp_processor (4.11.0)
151
- simplecov (0.16.1)
152
- docile (~> 1.1)
153
- json (>= 1.8, < 3)
154
- simplecov-html (~> 0.10.0)
155
- simplecov-html (0.10.2)
90
+ unicode-display_width (>= 1.4.0, < 1.7)
91
+ ruby-progressbar (1.10.1)
156
92
  thread_safe (0.3.6)
157
- unicode-display_width (1.4.1)
158
- virtus (1.0.5)
159
- axiom-types (~> 0.1)
160
- coercible (~> 1.0)
161
- descendants_tracker (~> 0.0, >= 0.0.3)
162
- equalizer (~> 0.0, >= 0.0.9)
163
- yard (0.9.18)
164
- yardstick (0.9.9)
165
- yard (~> 0.8, >= 0.8.7.2)
93
+ unicode-display_width (1.6.1)
94
+ variable (0.0.1)
95
+ equalizer (~> 0.0.11)
166
96
 
167
97
  PLATFORMS
168
98
  ruby
169
99
 
170
100
  DEPENDENCIES
171
- anima (~> 0.3.1)
172
- devtools (~> 0.1.23)
173
- morpher (~> 0.2.6)
174
- mutant!
101
+ mutant (~> 0.9.9)
102
+ mutant-license!
103
+ mutant-rspec (~> 0.9.9)
104
+ rspec (~> 3.9)
105
+ rspec-core (~> 3.9)
106
+ rspec-its (~> 1.2.0)
107
+ rubocop (~> 0.79.0)
175
108
  unparser!
176
109
 
177
110
  BUNDLED WITH