Hello community,

here is the log from the commit of package rubygem-netrc for openSUSE:Factory 
checked in at 2015-10-30 21:52:57
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/rubygem-netrc (Old)
 and      /work/SRC/openSUSE:Factory/.rubygem-netrc.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "rubygem-netrc"

Changes:
--------
--- /work/SRC/openSUSE:Factory/rubygem-netrc/rubygem-netrc.changes      
2015-03-03 11:14:40.000000000 +0100
+++ /work/SRC/openSUSE:Factory/.rubygem-netrc.new/rubygem-netrc.changes 
2015-10-30 21:52:58.000000000 +0100
@@ -1,0 +2,12 @@
+Fri Oct 30 05:33:05 UTC 2015 - [email protected]
+
+- updated to version 0.11.0
+ see installed changelog.txt
+
+  0.11.0 10/29/15
+  ===============
+  
+  Respect NETRC environment variable
+  Fix for JRuby PernGen Space
+
+-------------------------------------------------------------------

Old:
----
  netrc-0.10.3.gem

New:
----
  netrc-0.11.0.gem

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

Other differences:
------------------
++++++ rubygem-netrc.spec ++++++
--- /var/tmp/diff_new_pack.JxdWH1/_old  2015-10-30 21:52:59.000000000 +0100
+++ /var/tmp/diff_new_pack.JxdWH1/_new  2015-10-30 21:52:59.000000000 +0100
@@ -24,7 +24,7 @@
 #
 
 Name:           rubygem-netrc
-Version:        0.10.3
+Version:        0.11.0
 Release:        0
 %define mod_name netrc
 %define mod_full_name %{mod_name}-%{version}

++++++ netrc-0.10.3.gem -> netrc-0.11.0.gem ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/Readme.md new/Readme.md
--- old/Readme.md       2015-02-25 00:25:25.000000000 +0100
+++ new/Readme.md       2015-10-29 23:08:28.000000000 +0100
@@ -1,7 +1,7 @@
 # Netrc
 
 This library reads and writes
-[`.netrc` 
files](http://www.gnu.org/software/inetutils/manual/html_node/The-_002enetrc-File.html).
+[`.netrc` 
files](http://www.gnu.org/software/inetutils/manual/html_node/The-_002enetrc-file.html).
 
 ## API
 
@@ -13,8 +13,11 @@
 the filename ends in ".gpg", it will be decrypted using
 [GPG](http://www.gnupg.org/).
 
-Read the user's default netrc file. On Unix: `$HOME/.netrc`.
-On Windows: `%HOME%\_netrc`, `%HOMEDRIVE%%HOMEPATH%\_netrc`, or 
`%USERPROFILE%\_netrc` (whichever is set first).
+Read the user's default netrc file.
+
+**On Unix:** `$NETRC/.netrc` or `$HOME/.netrc` (whichever is set first).
+
+**On Windows:** `%NETRC%\_netrc`, `%HOME%\_netrc`, 
`%HOMEDRIVE%%HOMEPATH%\_netrc`, or `%USERPROFILE%\_netrc` (whichever is set 
first).
 
     n = Netrc.read
 
@@ -47,4 +50,4 @@
 ## Running Tests
 
     $ bundle install
-    $ bundle exec turn test
+    $ bundle exec ruby -e 'Dir.glob "./test/**/test_*.rb", &method(:require)'
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/changelog.txt new/changelog.txt
--- old/changelog.txt   2015-02-25 00:25:25.000000000 +0100
+++ new/changelog.txt   2015-10-29 23:08:28.000000000 +0100
@@ -1,3 +1,9 @@
+0.11.0 10/29/15
+===============
+
+Respect NETRC environment variable
+Fix for JRuby PernGen Space
+
 0.10.3 02/24/15
 ===============
 
Files old/checksums.yaml.gz and new/checksums.yaml.gz differ
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/lib/netrc.rb new/lib/netrc.rb
--- old/lib/netrc.rb    2015-02-25 00:25:25.000000000 +0100
+++ new/lib/netrc.rb    2015-10-29 23:08:28.000000000 +0100
@@ -1,14 +1,14 @@
 require 'rbconfig'
 
 class Netrc
-  VERSION = "0.10.3"
+  VERSION = "0.11.0"
 
   # see 
http://stackoverflow.com/questions/4871309/what-is-the-correct-way-to-detect-if-ruby-is-running-on-windows
   WINDOWS = RbConfig::CONFIG["host_os"] =~ /mswin|mingw|cygwin/
   CYGWIN  = RbConfig::CONFIG["host_os"] =~ /cygwin/
 
   def self.default_path
-    File.join(home_path, netrc_filename)
+    File.join(ENV['NETRC'] || home_path, netrc_filename)
   end
 
   def self.home_path
@@ -18,7 +18,7 @@
       home ||= File.join(ENV['HOMEDRIVE'], ENV['HOMEPATH']) if 
ENV['HOMEDRIVE'] && ENV['HOMEPATH']
       home ||= ENV['USERPROFILE']
       # XXX: old stuff; most likely unnecessary
-      home = home.gsub("\\", "/") unless home.nil?
+      home = home.tr("\\", "/") unless home.nil?
     end
 
     (home && File.readable?(home)) ? home : Dir.pwd
@@ -65,8 +65,25 @@
     new(path, parse(lex([])))
   end
 
+  class TokenArray < Array
+    def take
+      if length < 1
+        raise Error, "unexpected EOF"
+      end
+      shift
+    end
+
+    def readto
+      l = []
+      while length > 0 && ! yield(self[0])
+        l << shift
+      end
+      return l.join
+    end
+  end
+
   def self.lex(lines)
-    tokens = []
+    tokens = TokenArray.new
     for line in lines
       content, comment = line.split(/(\s*#.*)/m)
       content.each_char do |char|
@@ -96,6 +113,8 @@
     s =~ /^\s/
   end
 
+
+
   # Returns two values, a header and a list of items.
   # Each item is a tuple, containing some or all of:
   # - machine keyword (including trailing whitespace+comments)
@@ -110,19 +129,8 @@
   def self.parse(ts)
     cur, item = [], []
 
-    def ts.take
-      if length < 1
-        raise Error, "unexpected EOF"
-      end
-      shift
-    end
-
-    def ts.readto
-      l = []
-      while length > 0 && ! yield(self[0])
-        l << shift
-      end
-      return l.join
+    unless ts.is_a?(TokenArray)
+      ts = TokenArray.new(ts)
     end
 
     pre = ts.readto{|t| t == "machine" || t == "default"}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/metadata new/metadata
--- old/metadata        2015-02-25 00:25:25.000000000 +0100
+++ new/metadata        2015-10-29 23:08:28.000000000 +0100
@@ -1,7 +1,7 @@
 --- !ruby/object:Gem::Specification
 name: netrc
 version: !ruby/object:Gem::Version
-  version: 0.10.3
+  version: 0.11.0
 platform: ruby
 authors:
 - Keith Rarick
@@ -9,10 +9,10 @@
 autorequire: 
 bindir: bin
 cert_chain: []
-date: 2015-02-24 00:00:00.000000000 Z
+date: 2015-10-29 00:00:00.000000000 Z
 dependencies:
 - !ruby/object:Gem::Dependency
-  name: turn
+  name: minitest
   requirement: !ruby/object:Gem::Requirement
     requirements:
     - - ">="
@@ -68,7 +68,7 @@
       version: '0'
 requirements: []
 rubyforge_project: 
-rubygems_version: 2.4.5
+rubygems_version: 2.4.5.1
 signing_key: 
 specification_version: 4
 summary: Library to read and write netrc files.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/test/test_lex.rb new/test/test_lex.rb
--- old/test/test_lex.rb        2015-02-25 00:25:25.000000000 +0100
+++ new/test/test_lex.rb        2015-10-29 23:08:28.000000000 +0100
@@ -1,9 +1,9 @@
 $VERBOSE = true
-require 'test/unit'
+require 'minitest/autorun'
 
 require File.expand_path("#{File.dirname(__FILE__)}/../lib/netrc")
 
-class TestLex < Test::Unit::TestCase
+class TestLex < Minitest::Test
   def test_lex_empty
     t = Netrc.lex([])
     assert_equal([], t)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/test/test_netrc.rb new/test/test_netrc.rb
--- old/test/test_netrc.rb      2015-02-25 00:25:25.000000000 +0100
+++ new/test/test_netrc.rb      2015-10-29 23:08:28.000000000 +0100
@@ -1,11 +1,11 @@
 $VERBOSE = true
-require 'test/unit'
+require 'minitest/autorun'
 require 'fileutils'
 
 require File.expand_path("#{File.dirname(__FILE__)}/../lib/netrc")
 require "rbconfig"
 
-class TestNetrc < Test::Unit::TestCase
+class TestNetrc < Minitest::Test
 
   def setup
     Dir.glob('data/*.netrc').each{|f| File.chmod(0600, f)}
@@ -205,6 +205,13 @@
     ENV["HOME"], nil_home = nil_home, ENV["HOME"]
   end
 
+  def test_netrc_environment_variable
+    ENV["NETRC"] = File.join(Dir.pwd, 'data')
+    assert_equal File.join(Dir.pwd, 'data', '.netrc'), Netrc.default_path
+  ensure
+    ENV.delete("NETRC")
+  end
+
   def test_read_entry
     entry = Netrc.read("data/sample.netrc")['m']
     assert_equal 'l', entry.login
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/test/test_parse.rb new/test/test_parse.rb
--- old/test/test_parse.rb      2015-02-25 00:25:25.000000000 +0100
+++ new/test/test_parse.rb      2015-10-29 23:08:28.000000000 +0100
@@ -1,9 +1,9 @@
 $VERBOSE = true
-require 'test/unit'
+require 'minitest/autorun'
 
 require File.expand_path("#{File.dirname(__FILE__)}/../lib/netrc")
 
-class TestParse < Test::Unit::TestCase
+class TestParse < Minitest::Test
   def test_parse_empty
     pre, items = Netrc.parse([])
     assert_equal("", pre)


Reply via email to