Linux command
xxh 命令
文本
复制后可按需替换文件名、目录或参数。
常用示例
Connect to a host
xxh [hostname]
Connect using a specific shell
xxh [hostname] +s [zsh]
Connect with SSH arguments
xxh -i [~/.ssh/id_rsa] -p [2222] [hostname]
Install shell on first connect
xxh [hostname] +s [fish] +i
Install a plugin
xxh [hostname] +I [xxh-plugin-zsh-ohmyzsh]
Connect in hermetic mode
xxh [hostname] +hh
List available shells
xxh +LS
Remove xxh from remote host
xxh [hostname] +hc
说明
xxh brings your favorite shell and configurations to any remote host via SSH without requiring root access or system installations. It uploads portable versions of shells (zsh, fish, bash, xonsh) along with your plugins and configurations. When you run xxh host, it downloads a portable shell locally (cached for reuse), uploads it to the remote host's ~/.xxh directory, then connects via SSH and runs that shell. Your aliases, themes, and plugins work immediately. The tool is hermetic: removing the ~/.xxh directory from the remote host completely restores the original environment. Different hermetic levels control how isolated the xxh environment is from the system. Plugins extend functionality, adding tools like oh-my-zsh, powerlevel10k, or command-line utilities. Plugins are installed with +I plugin-name.
参数
- +s, +shell _shell_
- Specify shell to use (zsh, bash, fish, xonsh, osquery)
- +i, +install
- Install shell without confirmation prompts
- +I, +install-plugin _plugin_
- Install a plugin before connecting
- +hh, +hermetic-home
- Use hermetic home directory (~/.xxh isolated)
- +hc, +host-clean
- Remove xxh directory from remote host
- +LS, +list-shells
- List available portable shells
- +LP, +list-plugins
- List available plugins
- -i _keyfile_
- SSH identity file (passed to ssh)
- -p _port_
- SSH port (passed to ssh)
FAQ
What is the xxh command used for?
xxh brings your favorite shell and configurations to any remote host via SSH without requiring root access or system installations. It uploads portable versions of shells (zsh, fish, bash, xonsh) along with your plugins and configurations. When you run xxh host, it downloads a portable shell locally (cached for reuse), uploads it to the remote host's ~/.xxh directory, then connects via SSH and runs that shell. Your aliases, themes, and plugins work immediately. The tool is hermetic: removing the ~/.xxh directory from the remote host completely restores the original environment. Different hermetic levels control how isolated the xxh environment is from the system. Plugins extend functionality, adding tools like oh-my-zsh, powerlevel10k, or command-line utilities. Plugins are installed with +I plugin-name.
How do I run a basic xxh example?
Run `xxh [hostname]` in a terminal, then adjust file names, paths, flags, or remote targets for your system.
What does +s, +shell _shell_ do in xxh?
Specify shell to use (zsh, bash, fish, xonsh, osquery)