Merge remote-tracking branch 'upstream/master'

bug/bundler_fix
mumbai 2017-10-17 21:16:47 -04:00
commit 2f98f2bc2a
1 changed files with 5 additions and 4 deletions

View File

@ -132,9 +132,10 @@ module Shell
if framework
if input.prompt.include?("%T")
t = Time.now
if framework.datastore['PromptTimeFormat']
t = t.strftime(framework.datastore['PromptTimeFormat'])
end
# This %T is the strftime shorthand for %H:%M:%S
format = framework.datastore['PromptTimeFormat'] || "%T"
t = t.strftime(format)
# This %T is the marker in the prompt where we need to place the time
input.prompt.gsub!(/%T/, t.to_s)
end