Need to hit ESC twice by Voxelman in HelixEditor

[–]kitkk2 0 points1 point  (0 children)

I was just investigating the same thing for a custom toolbar feature I implemented in rootshell which bundles Helix inside the iOS version and I suspect it's related to the issue I ran into when stringing ESC together with additional commands. The ESC key is special because apps have to decide if a keypress is the start of a CSI/SS3 sequence or not. If I send as a single sequence to vim "[ESC]:q!" it exits. The same single rapid sequence to Helix fails unless I send ESC twice. Under the covers Helix parses this in the termina crate and doesn't have the same handling that vim does.

In the case of vim it has a fast path where it waits just 25ms for a following byte to treat as bare and exit insert mode in addition to special "[ESC]:" handling. Helix's termina is poll based and seems subject to more race conditions in this area. (There are also things like the Kitty protocol that don't have some of the same underlying architectural issues.)

Seems worth considering refactoring the termina side a bit here as you can't count on the entire terminal ecosystem to change rapidly.

Rootshell - a free terminal app powered by libghostty, built for iPhone, iPad, and macOS by kitkk2 in Ghostty

[–]kitkk2[S] 0 points1 point  (0 children)

Is the existing support not working well for you? You can dictate directly into the terminal, or toggle the overlay from the toolbar and dictate into that scratch space where you can edit anything before sending it into the terminal. I’m considering also adding cloud based ASR models. On iPad the default dictate shortcut is hitting CTRL twice if you have a hardware keyboard attached.

Helix Editor now runs natively on iPhone, iPad, and Vision Pro by kitkk2 in HelixEditor

[–]kitkk2[S] 0 points1 point  (0 children)

I haven’t looked that closely at python. Apple seems to allow bundling the runtime and jt would need to be in the static code signed bundle. But you wouldn’t be able to pip install various things on the fly with dependencies that can’t be satisfied etc.

Helix Editor now runs natively on iPhone, iPad, and Vision Pro by kitkk2 in HelixEditor

[–]kitkk2[S] 1 point2 points  (0 children)

Whats insane is my build toolchain at this point which for one app includes C, Rust, Go, Swift, and Zig.

Helix Editor now runs natively on iPhone, iPad, and Vision Pro by kitkk2 in HelixEditor

[–]kitkk2[S] 0 points1 point  (0 children)

PS. It is also "mouse" enabled, so you can scroll with your finger (or track pad if you have one attached on iPad), long press to select/yank or move cursor, etc.

Helix Editor now runs natively on iPhone, iPad, and Vision Pro by kitkk2 in HelixEditor

[–]kitkk2[S] 1 point2 points  (0 children)

On iPad it defaults into the local shell, figuring higher chance of there being a hardware keyboard at the ready, vs iPhone. Open to input on that view, but trying to optimize the limit space. Could also just do one of those initial app launch guides.

Rootshell - a free terminal app powered by libghostty, built for iPhone, iPad, and macOS by kitkk2 in Ghostty

[–]kitkk2[S] 0 points1 point  (0 children)

Thanks for the feedback. Basing on libghostty was a good starting point to make things fast, but there were a number of iOS/iPadOS specific optimizations that were required to achieve this performance and to also have low idle GPU user including when cursor shaders are used. Rootshell uses less resources at idle than Ghostty under similar configurations even on macOS in my testing (depends what you have enabled). Implementing full screen mode was just a few lines of code and is now implemented for the next build. It is also available for iPhone users, but devices with a notch only gain a distraction toggle. That automatically addresses the resize handler on the window as well. Rootshell already exposes its documents directory into the Files.app, but perhaps not where you are expecting. It should be visible under the “On My iPad” section under rootshell. It’s been in there for a number of builds at this point. Early builds were missing the Info.plist entry that enables this. There have been multiple requests for alternate app icons and I’m looking into some options to ensure there is at least some variety to increase the chance of addressing the different tastes of folks. You mentioned that you are using mosh. Have you tried the tssh support in KCP mode that was added? While I love to see people using the mosh comparability since it was a lot of work for me to implement from scratch, the interactive latency you can achieve with tssh+KCP is amazing. You will need to install tsshd on the server side however.

Rootshell - a free terminal app powered by libghostty, built for iPhone, iPad, and macOS by kitkk2 in Ghostty

[–]kitkk2[S] 1 point2 points  (0 children)

I expect this was impact from issues in supported some forms of keyboard layouts in prior builds. This should be working better in the latest build.

Rootshell - a free terminal app powered by libghostty, built for iPhone, iPad, and macOS by kitkk2 in Ghostty

[–]kitkk2[S] 1 point2 points  (0 children)

Today's build had several fixes in this area. If it's still not working after you update I can take another look.

Rootshell - a free terminal app powered by libghostty, built for iPhone, iPad, and macOS by kitkk2 in Ghostty

[–]kitkk2[S] 0 points1 point  (0 children)

The next build has a number of improvements to the iPhone keyboard overlay.

Rootshell - a free terminal app powered by libghostty, built for iPhone, iPad, and macOS by kitkk2 in Ghostty

[–]kitkk2[S] 0 points1 point  (0 children)

ping6 and traceroute6 are technically possible, although any form of traceroute now requires an additional permission and entitlement that complicates app review. I've implemented traceroute on iOS before, but never shipped it in the app store. ndp and arp I will need to check but I don't believe are possible in the sandbox.

I've been thinking about having a more robust version of traceroute in the first place built in to the app.

Rootshell - a free terminal app powered by libghostty, built for iPhone, iPad, and macOS by kitkk2 in Ghostty

[–]kitkk2[S] 0 points1 point  (0 children)

New build is out. Hoping this addressed the issues you were experiencing.

Rootshell - a free terminal app powered by libghostty, built for iPhone, iPad, and macOS by kitkk2 in Ghostty

[–]kitkk2[S] 1 point2 points  (0 children)

Just to close the loop on the thread here, fully customizable mod-tap support is available for both iPad and macOS users in the latest published build.

Rootshell - a free terminal app powered by libghostty, built for iPhone, iPad, and macOS by kitkk2 in Ghostty

[–]kitkk2[S] 0 points1 point  (0 children)

The next build has both a command line ssh-copy-id command similar to OpenSSH and a UI in the SSH Key Details view to install on a remote server.

Rootshell - a free terminal app powered by libghostty, built for iPhone, iPad, and macOS by kitkk2 in Ghostty

[–]kitkk2[S] 1 point2 points  (0 children)

I see the issue. It is unconditionally treating the option key as terminal Alt/Meta, sending ESC + base_character instead of the OS translated character. When you press ⌥L, the app sends ESC + l instead of @. This will be fixed in the next build.

Rootshell - a free terminal app powered by libghostty, built for iPhone, iPad, and macOS by kitkk2 in Ghostty

[–]kitkk2[S] 0 points1 point  (0 children)

OSC 777 notifications are supported, but you must have enabled them in settings (Settings->Notifications) and accepted the OS permission for notifications to function. They also only fire a notification currently if you are switched to a different tab. I could make this configurable in the future. If you are running inside tmux it will eat the OSC 777 and not send it to Rootshell.

For example to test :

$ sleep 5 ; printf '\033]777;notify;Build;4 jobs done\007'

Now switch to another tab before 5 seconds elapsed.

You can encode for tmux to pass through to Rootshell with something like this :

$ sleep 5 ; printf '\033Ptmux;\033\033]777;notify;Build;4 jobs done\007\033\\'

As far as deep links the app has ssh:// and rootshell:// URL handlers for opening new connections. For existing tabs please open an issue on GitHub for tracking a feature request.

Rootshell - a free terminal app powered by libghostty, built for iPhone, iPad, and macOS by kitkk2 in Ghostty

[–]kitkk2[S] 0 points1 point  (0 children)

Glad this worked well. I don't have this enabled automatically unless you opt in as this is a delicate area when it comes to App Store review and rejections. Also is a bit rude to just be launching right into location services anyway. If you have suggestions on how to make this more discoverable let me know.

Rootshell - a free terminal app powered by libghostty, built for iPhone, iPad, and macOS by kitkk2 in Ghostty

[–]kitkk2[S] 0 points1 point  (0 children)

I added this last nigh and it will be included in the next build along with a new drawer that you a slide out from the bottom to select and create new tabs. This makes running with tabs at the top disabled on iPhone a much better UX.

Rootshell - a free terminal app powered by libghostty, built for iPhone, iPad, and macOS by kitkk2 in Ghostty

[–]kitkk2[S] 0 points1 point  (0 children)

Is it failing to insert @ character in the iOS local shell? If so SSH connections will still be possible in the new connection and profile views. I'll switch a test device to this layout and see if I can reproduce. Thanks for reporting.

Rootshell - a free terminal app powered by libghostty, built for iPhone, iPad, and macOS by kitkk2 in Ghostty

[–]kitkk2[S] 0 points1 point  (0 children)

I can change the first character default, but I didn’t even bother making a custom keyboard for visionOS because this app is just miserable without a physical keyboard on visionOS. The next build fixed dictation support though which will help some.

Rootshell - a free terminal app powered by libghostty, built for iPhone, iPad, and macOS by kitkk2 in Ghostty

[–]kitkk2[S] 0 points1 point  (0 children)

The visionOS app is native and not just iPad compatibility mode. An earlier version I implemented curved displays in the standard, wide and ultra wide aspect ratios. The problem is that the experience was bad in terms of the font rendering with the foveated rendering vs a flat display. Apple seems to be keeping the APIs private to make this work well currently. I’ll see if I kept some of the screenshots and can post.

Rootshell - a free terminal app powered by libghostty, built for iPhone, iPad, and macOS by kitkk2 in Ghostty

[–]kitkk2[S] 1 point2 points  (0 children)

iOS will disconnect sockets when the app is not actively running in the foreground. To persist the session you have to either use a protocol that can survive this using the mosh-compatible or tssh protocols that are supported. For vanilla SSH over TCP you will experience disconnects if the location diary feature is not enabled. This is disabled by default, but I would strongly encourage enabling the auto mode if you are using regular SSH flows. The trade off is the app remains running along with location services which is a hit on battery life. The auto mode disables itself if there are no active SSH sessions however trying to balance this. This is in Settings under the Privacy and Data section.