Skip to content

Commit 566c330

Browse files
committed
Add workspace to prompt format options
1 parent e4d3888 commit 566c330

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

lib/rex/ui/text/shell.rb

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -178,6 +178,9 @@ def run(&block)
178178
input.prompt.gsub!(/%J/, framework.jobs.length.to_s)
179179
input.prompt.gsub!(/%L/, Rex::Socket.source_address("50.50.50.50"))
180180
input.prompt.gsub!(/%D/, ::Dir.getwd)
181+
if framework.db && framework.db.workspace
182+
input.prompt.gsub!(/%W/, framework.db.workspace.name)
183+
end
181184
self.init_prompt = input.prompt
182185
end
183186

0 commit comments

Comments
 (0)