Hello community,

here is the log from the commit of package rubygem-commander for 
openSUSE:Factory checked in at 2018-07-18 22:48:52
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/rubygem-commander (Old)
 and      /work/SRC/openSUSE:Factory/.rubygem-commander.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "rubygem-commander"

Wed Jul 18 22:48:52 2018 rev:23 rq:620993 version:4.4.5

Changes:
--------
--- /work/SRC/openSUSE:Factory/rubygem-commander/rubygem-commander.changes      
2018-02-10 17:59:49.408534752 +0100
+++ /work/SRC/openSUSE:Factory/.rubygem-commander.new/rubygem-commander.changes 
2018-07-18 22:48:57.347952467 +0200
@@ -1,0 +2,10 @@
+Tue May 22 19:02:56 UTC 2018 - [email protected]
+
+- updated to version 4.4.5
+ see installed History.rdoc
+
+  === 4.4.5 / 2018-05-22
+  
+  * Make internal command state less mutable. (@doriantaylor)
+
+-------------------------------------------------------------------

Old:
----
  commander-4.4.4.gem

New:
----
  commander-4.4.5.gem

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ rubygem-commander.spec ++++++
--- /var/tmp/diff_new_pack.3PYYId/_old  2018-07-18 22:48:57.959950438 +0200
+++ /var/tmp/diff_new_pack.3PYYId/_new  2018-07-18 22:48:57.959950438 +0200
@@ -24,7 +24,7 @@
 #
 
 Name:           rubygem-commander
-Version:        4.4.4
+Version:        4.4.5
 Release:        0
 %define mod_name commander
 %define mod_full_name %{mod_name}-%{version}

++++++ commander-4.4.4.gem -> commander-4.4.5.gem ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/History.rdoc new/History.rdoc
--- old/History.rdoc    2018-01-19 00:03:31.000000000 +0100
+++ new/History.rdoc    2018-05-22 20:58:31.000000000 +0200
@@ -1,3 +1,7 @@
+=== 4.4.5 / 2018-05-22
+
+* Make internal command state less mutable. (@doriantaylor)
+
 === 4.4.4 / 2018-01-18
 
 * Fix deprecated constant warnings on Ruby 2.5. (@mattbrictson)
Binary files old/checksums.yaml.gz and new/checksums.yaml.gz differ
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/lib/commander/command.rb new/lib/commander/command.rb
--- old/lib/commander/command.rb        2018-01-19 00:03:31.000000000 +0100
+++ new/lib/commander/command.rb        2018-05-22 20:58:31.000000000 +0200
@@ -171,9 +171,13 @@
     # Call the commands when_called block with _args_.
 
     def call(args = [])
-      object = @when_called.shift
-      meth = @when_called.shift || :call
+      object, meth = @when_called[0, 2]
+      meth ||= :call
       options = proxy_option_struct
+
+      # empty the proxy option stack before the next invocation
+      proxy_options.clear
+
       case object
       when Proc then object.call(args, options)
       when Class then meth != :call ? object.new.send(meth, args, options) : 
object.new(args, options)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/lib/commander/version.rb new/lib/commander/version.rb
--- old/lib/commander/version.rb        2018-01-19 00:03:31.000000000 +0100
+++ new/lib/commander/version.rb        2018-05-22 20:58:31.000000000 +0200
@@ -1,3 +1,3 @@
 module Commander
-  VERSION = '4.4.4'.freeze
+  VERSION = '4.4.5'.freeze
 end
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/metadata new/metadata
--- old/metadata        2018-01-19 00:03:31.000000000 +0100
+++ new/metadata        2018-05-22 20:58:31.000000000 +0200
@@ -1,7 +1,7 @@
 --- !ruby/object:Gem::Specification
 name: commander
 version: !ruby/object:Gem::Version
-  version: 4.4.4
+  version: 4.4.5
 platform: ruby
 authors:
 - TJ Holowaychuk
@@ -9,7 +9,7 @@
 autorequire: 
 bindir: bin
 cert_chain: []
-date: 2018-01-18 00:00:00.000000000 Z
+date: 2018-05-22 00:00:00.000000000 Z
 dependencies:
 - !ruby/object:Gem::Dependency
   name: highline
@@ -157,7 +157,7 @@
       version: '0'
 requirements: []
 rubyforge_project: 
-rubygems_version: 2.7.4
+rubygems_version: 2.6.11
 signing_key: 
 specification_version: 4
 summary: The complete solution for Ruby command-line executables
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/spec/command_spec.rb new/spec/command_spec.rb
--- old/spec/command_spec.rb    2018-01-19 00:03:31.000000000 +0100
+++ new/spec/command_spec.rb    2018-05-22 20:58:31.000000000 +0200
@@ -74,6 +74,16 @@
       it 'should raise an error when no handler is present' do
         expect { @command.when_called }.to raise_error(ArgumentError)
       end
+
+      it 'should be able to be run more than once' do
+        expect(@command.run('once')).to eql('test once')
+        expect(@command.run('twice')).to eql('test twice')
+      end
+
+      it 'should empty @proxy_options after running' do
+        expect(@command.run('--verbose')).to eql('test ')
+        expect(@command.proxy_options.empty?).to be true
+      end
     end
 
     describe 'should populate options with' do


Reply via email to