[Apt-listbugs-commits] [apt-listbugs] 01/11: Revert "avoid NameError with Ruby 1.8"

Francesco Poli frx-guest at moszumanska.debian.org
Sat Jun 4 16:53:07 UTC 2016


This is an automated email from the git hooks/post-receive script.

frx-guest pushed a commit to branch master
in repository apt-listbugs.

commit b8501afe0b8a30eac65ebd1cda4e7a5cbfcf9795
Author: Francesco Poli (wintermute) <invernomuto at paranoici.org>
Date:   Sat Jun 4 12:49:55 2016 +0200

    Revert "avoid NameError with Ruby 1.8"
    
    The support for Ruby 1.8 is long gone in Debian, so there is no
    point in keeping the temporary hack that helped apt-listbugs to also
    run with Ruby 1.8 ...
    
    This reverts commit 49107a2b019c7d09a97c76b0af38fdfeac145bfc.
---
 lib/aptlistbugs/logic.rb | 10 +---------
 1 file changed, 1 insertion(+), 9 deletions(-)

diff --git a/lib/aptlistbugs/logic.rb b/lib/aptlistbugs/logic.rb
index 75f5bb2..d185844 100644
--- a/lib/aptlistbugs/logic.rb
+++ b/lib/aptlistbugs/logic.rb
@@ -137,14 +137,6 @@ class AppConfig
       @parsestep = $1.to_i if $1.to_i > 0
     end
 
-    # this hack is not nice: it should be dropped, once
-    # Debian support for Ruby 1.8 is long gone
-    getoptlong_ambiguousoption = if RUBY_VERSION >= "1.9"
-      GetoptLong::AmbiguousOption
-    else
-      GetoptLong::AmbigousOption
-    end
-
     opt_parser = GetoptLong.new
     opt_parser.set_options(['--help', '-h', GetoptLong::NO_ARGUMENT],
                            ['--severity', '-s', GetoptLong::REQUIRED_ARGUMENT],
@@ -211,7 +203,7 @@ class AppConfig
           @force_pin = true
         end
       }
-    rescue getoptlong_ambiguousoption, GetoptLong::NeedlessArgument,
+    rescue GetoptLong::AmbiguousOption, GetoptLong::NeedlessArgument,
         GetoptLong::MissingArgument, GetoptLong::InvalidOption
       usage
       exit 1

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/apt-listbugs/apt-listbugs.git



More information about the Apt-listbugs-commits mailing list