-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Terminal can be launched with a specified command #38
base: main
Are you sure you want to change the base?
Conversation
Added option :command to API and --command command line. - screenshot :play/--play option is now optional - Adapted sample play scripts to run /bin/bash as part of setup. On my system I run zsh with powerlevel10k and my fancy prompts were getting into README screenshots. - On macOS and Linux :command defaults to $SHELL else /bin/bash - Included support to default :command to powershell if on Windows. This gets us past launch, but there are still be many issues on Windows. Contributes to phronmophobic#29 - See README and docstrings for details on usage Closes phronmophobic#3
@phronmophobic, previously the hardcoded launch command was |
To be honest, I'm not sure. From the docs, it seems like It would be interesting to check what other terminal emulators are doing. Additionally, I've only been running |
Here's some interesting info in kitty: |
More references: As far as I can tell, it seems like passing |
Thanks for the references! Only skimmed, will read more carefully tomorrow. I'm thinking that turfing automatically using |
I've read these tickets a few times now and I'm still not 100% sure. It seems like on macOS, you want to login mainly to load Based on the tickets, it looks like rather than passing
I think the above fix also would work if we use
Even if the above change would fix using |
Thanks for all the follow-up investigations! I've been distracted with advent-of-code puzzles! From the bash man page (same text for macOS and Linux), I see:
So maybe the 2 techniques are equivalent? But what if I am using a different shell? I'm not very shell-variant savvy but have used The man page for
As the veil of naivete lifts, I expect this is probably a convention? So yeah, maybe we can still default to But the question remains, only for macOS or also for Linux? |
That's what I was thinking as well. The reason I think we should prefer using the "-" prefix over the
As far as I can tell, requiring a login shell is only required for macOS. That's also how the other terminal emulators seem to behave. |
Okay, sounds good, thanks! |
Okay, better recap the macOS login shell issue. Due to the way Apple decided to initialize shells, on macOS only, new shells should be created as login terminals (our surveyed terminals all do this). This is not needed/wanted/necessary on Linux. There are three options for shells macOS:
Here are the possible valid values for our new
Note that membrane.term does not distinguish between user command and user shell, it just sees a Okay, now let's look at our options:
Implementation complexities. Option 3 is more technically complex for membrane.term than option 2. |
Had a quick peek just now. I so almost had a clever solution to dash prefixing on macOS with pty4j. I figured I could create a Clojure Alas, the |
Even though we will likely do something here in the meantime, it would be better if pty4j supported this in its higher-level APIs. I've raised an issue over there to see if there is any interest. |
Added option :command to API and --command command line.
of setup. On my system I run zsh with powerlevel10k and
my fancy prompts were getting into README screenshots.
/bin/bash
Windows. This gets us past launch, but there
are still be many issues on Windows.
Contributes to Consider Supporting Windows #29
Closes #3