shellutils 0.0.10 → 0.0.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/lib/shellutils.rb +2 -2
- data/lib/shellutils/version.rb +1 -1
- metadata +1 -1
data/lib/shellutils.rb
CHANGED
|
@@ -123,7 +123,7 @@ module ShellUtils
|
|
|
123
123
|
w.sync = true
|
|
124
124
|
w.flush
|
|
125
125
|
puts "-4" if DEBUG
|
|
126
|
-
if r.expect(/[Pp]assword
|
|
126
|
+
if r.expect(/[Pp]assword.*:.*$/, 10)
|
|
127
127
|
puts "-5" if DEBUG
|
|
128
128
|
w.flush
|
|
129
129
|
w.puts(get_sudo_pwd)
|
|
@@ -132,7 +132,7 @@ module ShellUtils
|
|
|
132
132
|
begin
|
|
133
133
|
w.flush
|
|
134
134
|
puts "-7" if DEBUG
|
|
135
|
-
if r.expect(/[Pp]assword
|
|
135
|
+
if r.expect(/[Pp]assword.*:.*$/, 10)
|
|
136
136
|
error("the sudo password is incorrect. password=#{get_sudo_pwd}\nPlease change the password ex) set_sudo_pwd PASSWORD")
|
|
137
137
|
end
|
|
138
138
|
rescue
|
data/lib/shellutils/version.rb
CHANGED