Skip to content

Support for persistent bash-terminal sessions #9

Description

@Jacob-Hunt

Is your feature request related to a problem? Please describe.
Right now, the "!bash" command works by opening a new instance of the "terminal" program, executing the specified bash command, then exiting. This leads to the program essentially freezing (or, more accurately, timing out after a number of minutes) when interactive terminal programs (command-line python, vim, etc.) are run, thus severely limiting the realism of the terminal experience.

Describe the solution you'd like
Either restructuring the implementation of "!bash" to more closely simulate the experience of using a bash terminal, or creating a new command (such as "!bash-session terminal-name") which will initiate a new terminal session ("terminal-name") which provides a persistent terminal for the user.

Describe alternatives you've considered
Many attempts were made to implement "!bash" as a persistent terminal session, but the difficulties encountered led to the prioritization of a more stripped-down degree of functionality so as to be able to release a minimal version of the program more quickly. Ultimately, the ability to keep track of the current working directory and execute singular bash commands was deemed a sufficient minimal level of functionality.

Additional context
Add any other context or screenshots about the feature request here.

Attempts to implement persistent terminals involved a great deal of experimentation with the Python3 "subprocess" module (https://docs.python.org/3/library/subprocess.html), more specifically the Popen class (https://docs.python.org/3/library/subprocess.html#popen-objects), and this experimentation ultimately led to the program's current form. Though it may be possible to implement persistent terminal sessions using the subprocess module, future attempts to implement this feature may yield more success by considering alternative approaches.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions