summaryrefslogtreecommitdiff
path: root/tool/vcs.rb
diff options
context:
space:
mode:
authorNobuyoshi Nakada <nobu@ruby-lang.org>2019-06-28 12:41:03 +0900
committerNobuyoshi Nakada <nobu@ruby-lang.org>2019-06-28 12:41:03 +0900
commitbe14f62cafff30a6127c6ff533fec6de232ba7dd (patch)
treea0efa9cfc287c3d2d477474736f3142074fd1a8d /tool/vcs.rb
parent4562dad94c6af3db5af8704b0aec64119456275d (diff)
Default @debug to $DEBUG
Diffstat (limited to 'tool/vcs.rb')
-rw-r--r--tool/vcs.rb1
1 files changed, 1 insertions, 0 deletions
diff --git a/tool/vcs.rb b/tool/vcs.rb
index 34ec6a4..4554da3 100644
--- a/tool/vcs.rb
+++ b/tool/vcs.rb
@@ -164,6 +164,7 @@ class VCS
parser.on("--[no-]dryrun") {|v| @dryrun = v}
parser.on("--[no-]debug") {|v| @debug = v}
parser.parse(opts)
+ @debug = $DEBUG unless defined?(@debug)
@dryrun = @debug unless defined?(@dryrun)
when Hash
unless (keys = opts.keys - [:debug, :dryrun]).empty?