diff --git a/aiida/transports/plugins/ssh.py b/aiida/transports/plugins/ssh.py index 9f73bdbc14..5f1a765608 100644 --- a/aiida/transports/plugins/ssh.py +++ b/aiida/transports/plugins/ssh.py @@ -1265,7 +1265,7 @@ def _exec_command_internal(self, command, combine_stderr=False, bufsize=-1): # if self.getcwd() is not None: escaped_folder = escape_for_bash(self.getcwd()) - command_to_execute = (f'cd {escaped_folder} && {command}') + command_to_execute = (f'cd {escaped_folder} && ( {command} )') else: command_to_execute = command