diff --git a/tool/merger.rb b/tool/merger.rb index 5f48f2eeca4b02..56b7b4a0684a8a 100755 --- a/tool/merger.rb +++ b/tool/merger.rb @@ -222,7 +222,7 @@ def commit(file) def svn_mode? return @svn_mode if defined?(@svn_mode) - @svn_mode = system("svn info > #{IO::NULL} 2>&1") + @svn_mode = system("svn info", %i(out err) => IO::NULL) end # Prints the version of Ruby found in version.h diff --git a/tool/redmine-backporter.rb b/tool/redmine-backporter.rb index 1ac001bb6edb53..a7bce96fe29569 100755 --- a/tool/redmine-backporter.rb +++ b/tool/redmine-backporter.rb @@ -436,7 +436,7 @@ class << @changesets next end - if system("svn info #{RUBY_REPO_PATH&.shellescape} > #{IO::NULL} 2>&1") # SVN + if system("svn info #{RUBY_REPO_PATH&.shellescape}", %i(out err) => IO::NULL) # SVN if log = find_svn_log("##@issue]") && /revision="(?\d+)/ =~ log rev = "r#{rev}" end