New Upstream Snapshot - ruby-concord
Ready changes
Summary
Merged new upstream version: 0.1.6 (was: 0.1.5).
Resulting package
Built on 2022-11-09T19:12 (took 9m13s)
The resulting binary packages can be installed (if you have the apt repository enabled) by running one of:
apt install -t fresh-snapshots ruby-concord
Lintian Result
Diff
diff --git a/.circle.yml b/.circle.yml
deleted file mode 100644
index 44459de..0000000
--- a/.circle.yml
+++ /dev/null
@@ -1,4 +0,0 @@
----
-test:
- override:
- - bundle exec rake ci
diff --git a/.gitignore b/.gitignore
deleted file mode 100644
index be5bd95..0000000
--- a/.gitignore
+++ /dev/null
@@ -1,4 +0,0 @@
-/tmp
-/Gemfile.lock
-/.bundle
-/vendor
diff --git a/.rubocop.yml b/.rubocop.yml
index 101ca1d..19b9ac0 100644
--- a/.rubocop.yml
+++ b/.rubocop.yml
@@ -1,7 +1,6 @@
AllCops:
- Includes:
+ Include:
- 'Gemfile'
- Excludes:
- - 'Gemfile.devtools'
+ Exclude:
- 'vendor/**'
- 'benchmarks/**'
diff --git a/.travis.yml b/.travis.yml
index 936a078..ff54e74 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -1,17 +1,14 @@
language: ruby
script: 'bundle exec rake ci'
rvm:
- - 1.9.3
- - 2.0.0
- - jruby-19mode
- - jruby-head
+ - '1.9'
+ - '2.0'
+ - '2.1'
+ - '2.2'
- rbx
matrix:
- allow_failures:
- - rvm: ruby-head
-notifications:
- irc:
- channels:
- - irc.freenode.org#rom-rb
- on_success: never
- on_failure: change
+ include:
+ - rvm: jruby
+ env: JRUBY_OPTS="$JRUBY_OPTS --debug --1.9"
+ - rvm: jruby
+ env: JRUBY_OPTS="$JRUBY_OPTS --debug --2.0"
diff --git a/Changelog.md b/Changelog.md
index 008ec72..a44b82d 100644
--- a/Changelog.md
+++ b/Changelog.md
@@ -1,3 +1,7 @@
+# v0.1.6 2020-09-10
+
+* Change packaging to avoid git interaction
+
# v0.1.5 2014-04-10
* Dependency bumps
diff --git a/Gemfile b/Gemfile
index 8f1cfd3..81be6f4 100644
--- a/Gemfile
+++ b/Gemfile
@@ -1,6 +1,12 @@
+# frozen_string_literal: true
+
source 'https://rubygems.org'
gemspec
-gem 'devtools', git: 'https://github.com/rom-rb/devtools.git', branch: 'master'
-eval_gemfile 'Gemfile.devtools'
+gem 'mutant'
+gem 'mutant-rspec'
+
+source 'https://oss:Px2ENN7S91OmWaD5G7MIQJi1dmtmYrEh@gem.mutant.dev' do
+ gem 'mutant-license'
+end
diff --git a/Gemfile.devtools b/Gemfile.devtools
deleted file mode 100644
index c9db0bb..0000000
--- a/Gemfile.devtools
+++ /dev/null
@@ -1,71 +0,0 @@
-# encoding: utf-8
-
-group :development do
- gem 'rake', '~> 10.2.1'
- gem 'rspec', '~> 2.14.1'
- gem 'rspec-core', '~> 2.14.8'
- gem 'yard', '~> 0.8.7.4'
-
- platform :rbx do
- gem 'rubysl-singleton', '~> 2.0.0'
- end
-end
-
-group :yard do
- gem 'kramdown', '~> 1.3.3'
-end
-
-group :guard do
- gem 'guard', '~> 2.6.0'
- gem 'guard-bundler', '~> 2.0.0'
- gem 'guard-rspec', '~> 4.2.8'
- gem 'guard-rubocop', '~> 1.0.2'
-
- # file system change event handling
- gem 'listen', '~> 2.7.1'
- gem 'rb-fchange', '~> 0.0.6', require: false
- gem 'rb-fsevent', '~> 0.9.4', require: false
- gem 'rb-inotify', '~> 0.9.3', require: false
-
- # notification handling
- gem 'libnotify', '~> 0.8.2', require: false
- gem 'rb-notifu', '~> 0.0.4', require: false
- gem 'terminal-notifier-guard', '~> 1.5.3', require: false
-end
-
-group :metrics do
- gem 'coveralls', '~> 0.7.0'
- gem 'flay', '~> 2.4.0'
- gem 'flog', '~> 4.2.0'
- gem 'reek', '~> 1.3.7'
- gem 'rubocop', '~> 0.19.1'
- gem 'simplecov', '~> 0.8.2'
- gem 'yardstick', '~> 0.9.9'
-
- platforms :mri do
- gem 'mutant', '~> 0.5.10'
- gem 'mutant-rspec', '~> 0.5.10'
- end
-
- platforms :ruby_19, :ruby_20 do
- gem 'yard-spellcheck', '~> 0.1.5'
- end
-
- platform :rbx do
- gem 'json', '~> 1.8.1'
- gem 'racc', '~> 1.4.11'
- gem 'rubysl-logger', '~> 2.0.0'
- gem 'rubysl-open-uri', '~> 2.0.0'
- gem 'rubysl-prettyprint', '~> 2.0.3'
- end
-end
-
-group :benchmarks do
- gem 'rbench', '~> 0.2.3'
-end
-
-platform :jruby do
- group :jruby do
- gem 'jruby-openssl', '~> 0.8.5'
- end
-end
diff --git a/README.md b/README.md
index 51fe9c0..144d7b4 100644
--- a/README.md
+++ b/README.md
@@ -1,9 +1,8 @@
concord
=======
-[![Build Status](https://secure.travis-ci.org/mbj/concord.png?branch=master)](http://travis-ci.org/mbj/concord)
-[![Dependency Status](https://gemnasium.com/mbj/concord.png)](https://gemnasium.com/mbj/concord)
-[![Code Climate](https://codeclimate.com/github/mbj/concord.png)](https://codeclimate.com/github/mbj/concord)
+[![Gem Version](http://img.shields.io/gem/v/concord.svg)][https://rubygems.org/gems/concord]
+![CI](https://github.com/mbj/concord/workflows/CI/badge.svg)
Library to transform this:
@@ -52,7 +51,7 @@ class ComposedObject
end
```
-Sure the replacement is missing YARD docs, but IMHO it is better.
+You can still add YARD docs for generated interface.
Rubies
------
@@ -62,7 +61,7 @@ Tested under all >= 1.9 rubies.
Installation
------------
-Install the gem `concord` via your prefered method.
+Install the gem `concord` via your preferred method.
Credits
-------
diff --git a/circle.yml b/circle.yml
deleted file mode 100644
index 44459de..0000000
--- a/circle.yml
+++ /dev/null
@@ -1,4 +0,0 @@
----
-test:
- override:
- - bundle exec rake ci
diff --git a/concord.gemspec b/concord.gemspec
index 67e52a7..d7512a1 100644
--- a/concord.gemspec
+++ b/concord.gemspec
@@ -1,22 +1,20 @@
-# -*- encoding: utf-8 -*-
-
Gem::Specification.new do |s|
s.name = 'concord'
- s.version = '0.1.5'
+ s.version = '0.1.6'
s.authors = ['Markus Schirp']
s.email = ['mbj@schirp-dso.com']
s.homepage = 'https://github.com/mbj/concord'
- s.summary = %q{Helper for object composition}
+ s.summary = 'Helper for object composition'
s.license = 'MIT'
s.description = s.summary
- s.files = `git ls-files`.split("\n")
- s.test_files = `git ls-files -- {spec}/*`.split("\n")
- s.executables = []
- s.require_paths = ['lib']
+ s.files = Dir.glob('lib/**/*')
+ s.require_paths = %w(lib)
s.required_ruby_version = '>= 1.9.3'
s.add_dependency('adamantium', '~> 0.2.0')
s.add_dependency('equalizer', '~> 0.0.9')
+
+ s.add_development_dependency('devtools', '~> 0.1.26')
end
diff --git a/config/mutant.yml b/config/mutant.yml
index c5f05d9..42adfa5 100644
--- a/config/mutant.yml
+++ b/config/mutant.yml
@@ -1,3 +1,2 @@
-name: concord
-namespace: Concord
-strategy: --rspec-unit
+---
+integration: rspec
diff --git a/config/rubocop.yml b/config/rubocop.yml
index 39b5888..0c154c9 100644
--- a/config/rubocop.yml
+++ b/config/rubocop.yml
@@ -1,20 +1,10 @@
inherit_from: ../.rubocop.yml
-AllCops:
- Includes:
- - '**/*.rake'
- - 'Gemfile'
- - 'Gemfile.triage'
-
# Avoid parameter lists longer than five parameters.
ParameterLists:
Max: 3
CountKeywordArgs: true
-MethodLength:
- CountComments: false
- Max: 15
-
# Avoid more than `Max` levels of nesting.
BlockNesting:
Max: 3
@@ -27,30 +17,25 @@ CollectionMethods:
find: 'detect'
find_all: 'select'
-# Limit line length
-LineLength:
- Max: 113 # TODO: lower to 79 once the rubocop branch in shared/Gemfile is removed
-
-ClassLength:
- Max: 204
-
-# Disabled because of indenting with private keyword in class bodies.
-IndentationWidth:
- Enabled: false
-
-# I like raise more
-SignalException:
+# Do not force public/protected/private keyword to be indented at the same
+# level as the def keyword. My personal preference is to outdent these keywords
+# because I think when scanning code it makes it easier to identify the
+# sections of code and visually separate them. When the keyword is at the same
+# level I think it sort of blends in with the def keywords and makes it harder
+# to scan the code and see where the sections are.
+AccessModifierIndentation:
Enabled: false
-# False positive in unparser source
-OneLineConditional:
- Enabled: false
+# Limit line length
+LineLength:
+ Max: 106
+# Disable documentation checking until a class needs to be documented once
Documentation:
Enabled: false
-# Disable documentation checking until a class needs to be documented once
-Documentation:
+# Do not always use &&/|| instead of and/or.
+AndOr:
Enabled: false
# Do not favor modifier if/unless usage when you have a single-line body
@@ -69,14 +54,60 @@ ConstantName:
TrivialAccessors:
Enabled: false
-# Do not prefer do/end over {} for multiline blocks
-Blocks:
+# Allow empty lines around class body
+EmptyLinesAroundClassBody:
Enabled: false
-# I like to have an empty line before closing the currently opened body
-EmptyLinesAroundBody:
+# Allow empty lines around module body
+EmptyLinesAroundModuleBody:
Enabled: false
-# I like my style more
-AccessModifierIndentation:
+# Allow empty lines around block body
+EmptyLinesAroundBlockBody:
+ Enabled: false
+
+# Allow multiple line operations to not require indentation
+MultilineOperationIndentation:
+ Enabled: false
+
+# Prefer String#% over Kernel#sprintf
+FormatString:
+ Enabled: false
+
+# Use square brackets for literal Array objects
+PercentLiteralDelimiters:
+ PreferredDelimiters:
+ '%': '{}'
+ '%i': '[]'
+ '%q': ()
+ '%Q': ()
+ '%r': '{}'
+ '%s': ()
+ '%w': '[]'
+ '%W': '[]'
+ '%x': ()
+
+# Align if/else blocks with the variable assignment
+EndAlignment:
+ AlignWith: variable
+
+# Do not always align parameters when it is easier to read
+AlignParameters:
+ Exclude:
+ - spec/**/*_spec.rb
+
+# Prefer #kind_of? over #is_a?
+ClassCheck:
+ EnforcedStyle: kind_of?
+
+# Do not prefer double quotes to be used when %q or %Q is more appropriate
+UnneededPercentQ:
+ Enabled: false
+
+# Allow a maximum ABC score
+Metrics/AbcSize:
+ Max: 21.02
+
+# Do not prefer lambda.call(...) over lambda.(...)
+LambdaCall:
Enabled: false
diff --git a/debian/changelog b/debian/changelog
index 3a442cd..a602c66 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,9 @@
+ruby-concord (0.1.6-1) UNRELEASED; urgency=low
+
+ * New upstream release.
+
+ -- Debian Janitor <janitor@jelmer.uk> Wed, 09 Nov 2022 19:05:06 -0000
+
ruby-concord (0.1.5-3) unstable; urgency=medium
[ Cédric Boutillier ]
diff --git a/lib/concord.rb b/lib/concord.rb
index ebb6512..eb2c474 100644
--- a/lib/concord.rb
+++ b/lib/concord.rb
@@ -26,11 +26,10 @@ class Concord < Module
#
def initialize(*names)
if names.length > MAX_NR_OF_OBJECTS
- raise "Composition of more than #{MAX_NR_OF_OBJECTS} objects is not allowed"
+ fail "Composition of more than #{MAX_NR_OF_OBJECTS} objects is not allowed"
end
- @names = names
- @module = Module.new
+ @names, @module = names, Module.new
define_initialize
define_readers
define_equalizer
@@ -38,8 +37,6 @@ class Concord < Module
# Hook run when module is included
#
- # @param [Class|Module] descendant
- #
# @return [undefined]
#
# @api private
@@ -50,8 +47,6 @@ class Concord < Module
# Define equalizer
#
- # @param [Class|Module] descendant
- #
# @return [undefined]
#
# @api private
@@ -62,8 +57,6 @@ class Concord < Module
# Define readers
#
- # @param [Class|Module] descendant
- #
# @return [undefined]
#
# @api private
@@ -78,19 +71,19 @@ class Concord < Module
# Define initialize method
#
- # @param [Class|Module] descendant
- #
# @return [undefined]
#
# @api private
#
+ # rubocop:disable MethodLength
+ #
def define_initialize
ivars, size = instance_variable_names, names.size
@module.class_eval do
define_method :initialize do |*args|
args_size = args.size
if args_size != size
- raise ArgumentError, "wrong number of arguments (#{args_size} for #{size})"
+ fail ArgumentError, "wrong number of arguments (#{args_size} for #{size})"
end
ivars.zip(args) { |ivar, arg| instance_variable_set(ivar, arg) }
end
diff --git a/mutant.sh b/mutant.sh
new file mode 100755
index 0000000..d6e103c
--- /dev/null
+++ b/mutant.sh
@@ -0,0 +1,10 @@
+#/usr/bin/bash -ex
+
+bundle exec mutant \
+ --zombie \
+ --ignore-subject Concord#define_equalizer \
+ --ignore-subject Concord#define_initialize \
+ --ignore-subject Concord#define_readers \
+ --ignore-subject Concord#included \
+ --ignore-subject Concord::Public#included \
+ -- 'Concord*'
diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb
index e8bc4a8..424be24 100644
--- a/spec/spec_helper.rb
+++ b/spec/spec_helper.rb
@@ -1,3 +1 @@
-require 'devtools'
require 'concord'
-Devtools.init_spec_helper
diff --git a/spec/unit/concord/universal_spec.rb b/spec/unit/concord/universal_spec.rb
index 0e86fe6..d03331c 100644
--- a/spec/unit/concord/universal_spec.rb
+++ b/spec/unit/concord/universal_spec.rb
@@ -98,22 +98,22 @@ describe Concord do
context 'equalization behavior' do
specify 'composed objects are equalized on attributes' do
- expect(instance_a).to eql(instance_b)
+ expect(instance_a).to eql(instance_b)
expect(instance_a.hash).to eql(instance_b.hash)
- expect(instance_a).to eql(instance_b)
- expect(instance_a).to_not be(instance_c)
- expect(instance_a).to_not eql(instance_c)
+ expect(instance_a).to eql(instance_b)
+ expect(instance_a).to_not be(instance_c)
+ expect(instance_a).to_not eql(instance_c)
end
end
context 'when composing too many objects' do
specify 'it raises an error' do
- expect {
+ expect do
Concord.new(:a, :b, :c, :d)
- }.to raise_error(RuntimeError, 'Composition of more than 3 objects is not allowed')
- expect {
+ end.to raise_error(RuntimeError, 'Composition of more than 3 objects is not allowed')
+ expect do
Concord.new(:a, :b, :c)
- }.to_not raise_error
+ end.to_not raise_error
end
end
Debdiff
[The following lists of changes regard files as different if they have different names, permissions or owners.]
Files in second set of .debs but not in first
-rw-r--r-- root/root /usr/share/rubygems-integration/all/gems/concord-0.1.6/lib/concord.rb -rw-r--r-- root/root /usr/share/rubygems-integration/all/specifications/concord-0.1.6.gemspec
Files in first set of .debs but not in second
-rw-r--r-- root/root /usr/share/rubygems-integration/all/gems/concord-0.1.5/config/flay.yml -rw-r--r-- root/root /usr/share/rubygems-integration/all/gems/concord-0.1.5/config/flog.yml -rw-r--r-- root/root /usr/share/rubygems-integration/all/gems/concord-0.1.5/config/mutant.yml -rw-r--r-- root/root /usr/share/rubygems-integration/all/gems/concord-0.1.5/config/reek.yml -rw-r--r-- root/root /usr/share/rubygems-integration/all/gems/concord-0.1.5/config/roodi.yml -rw-r--r-- root/root /usr/share/rubygems-integration/all/gems/concord-0.1.5/config/rubocop.yml -rw-r--r-- root/root /usr/share/rubygems-integration/all/gems/concord-0.1.5/config/yardstick.yml -rw-r--r-- root/root /usr/share/rubygems-integration/all/gems/concord-0.1.5/lib/concord.rb -rw-r--r-- root/root /usr/share/rubygems-integration/all/specifications/concord-0.1.5.gemspec
Control files: lines which differ (wdiff format)
Ruby-Versions: all