Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion wharfee/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -1215,7 +1215,9 @@ def on_after_interactive():
# prompt is back to beginning of line
self.is_refresh_containers = True
self.is_refresh_running = True
return ['\rInteractive terminal is closed.']
if is_interactive or is_tty:
return ['\rInteractive terminal is closed.']
return []

def on_after_attach():
self.is_refresh_containers = True
Expand Down
3 changes: 3 additions & 0 deletions wharfee/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -339,6 +339,9 @@ def run_cli(self):
self.logger.error("traceback: %r", traceback.format_exc())
click.secho(str(ex), fg='red')

if '-i' in sys.argv or '-t' in sys.argv:
print('Interactive terminal is closed.')

self.revert_less_opts()
self.write_config_file()
print('Goodbye!')
Expand Down
4 changes: 4 additions & 0 deletions wharfee/options.py
Original file line number Diff line number Diff line change
Expand Up @@ -743,6 +743,10 @@ def parse_command_options(cmd, params):
if opt.default is not None:
popts[opt.dest] = opt.default

# Check for interactive terminal options
if '-i' in params or '-t' in params:
print("Interactive terminal is closed.")

return parser, popts, pargs


Expand Down