Fish and bare-readline end the edited line with LF only; many SSH PTYs do not
return the cursor to column 0, so ls/man and other command output started
mid-row. Write `\r` after releasing the line editor and before execShellLine
to align output with the peer terminal.
completion) when BARE_OS_FISH is not 0, matching the in-app terminal.
Keep bare-readline + per-command recycle only as fallback. Wire
suspendReplForSubprocess / resumeReplAfterSubprocess on the SSH child ctx to
suspendFishStdinForSubprocess / resume on the channel stream so baretop and
edit release the correct stdin.
Teardown: disableFishRawMode + releaseFishStdin when the session ends.
PTY env sync now only updates COLUMNS and LINES. Writing the client TERM
(e.g. xterm-256color) into the forked session env enabled baretop’s default
incremental line-diff, which mis-renders over SSH. Inherited guest TERM is
unchanged, matching in-app terminal behavior.
multiline output (e.g. man, bare-slice pager) matches real PTY behavior and
avoids misaligned lines vs the peer terminal.
Mirror pty-req TERM and dimensions into forked session vfs.env (COLUMNS,
LINES) when bareOsForkShellEnv is used; clear target on session end.
Add bare-openssh-pty-console helper module and brittle tests; re-export
formatter from bare-openssh for API parity.
AsyncFunction bodies used global console.log, so ./script.js output over SSH
went to Pear instead of the session TTY. Prepend var console = ctx.console
when ctx.console is present.
bare-readline treats empty prompt as falsy and defaults to ">"; each SSH
readline recycle painted that before setPrompt. Pass initialPrompt from
the real PS1, defer first attach until after profile/barerc, and skip the
extra \\r\\n after recycled bare-readline.
Close bare-readline before each execShellLine and attach a new session
afterward so fullscreen apps own stdin; avoids a corrupted KeyDecoder
and a frozen prompt when baretop/edit exit.
Wire pty-req and window-change to set columns/rows on the session
stream so /bin/edit (nano) and similar apps use the real terminal
geometry instead of defaulting to 80x24.
Route replStdin, replStdout, and stdout to the SSH channel Duplex so
/bin/edit (nano) and other TUI tools use the remote terminal instead of
Pear CLI. Mark exec channels as TTY for ssh ... nano style invocations.