The following command establishes an SSH connection to a server, executes several commands (for example, changing to a subdirectory and running `git status` ), and leaves the shell open. This loads the `.bashrc` file, which enables colored subshells. The trick is to save a temporary file `/tmp/initfile` containing the desired commands and start a subshell (in our case, `bash`) with the `--init-file` command. Within this `initfile`, the same file is immediately deleted to leave no trace.
ded8ef4a32a5fb8fb7a9c1b74a7d4279