https://github.com/regular/html-terminal
A terminal emulator based on web technologies
https://github.com/regular/html-terminal
htmshell nodejs terminal-emulators webkit
Last synced: 10 months ago
JSON representation
A terminal emulator based on web technologies
- Host: GitHub
- URL: https://github.com/regular/html-terminal
- Owner: regular
- Created: 2017-01-30T18:26:24.000Z (almost 9 years ago)
- Default Branch: master
- Last Pushed: 2017-02-20T11:21:02.000Z (almost 9 years ago)
- Last Synced: 2024-12-31T09:46:56.690Z (12 months ago)
- Topics: htmshell, nodejs, terminal-emulators, webkit
- Language: JavaScript
- Homepage:
- Size: 167 KB
- Stars: 9
- Watchers: 1
- Forks: 3
- Open Issues: 13
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
html-terminal
===
Terminal emulator based on web technologies.
## TL;DR
> I heard you like the terminal and the web, so I put a terminal in your browser and an HTML renderer in your terminal, so you can hack while you browse and browse while you hack!
html-terminal is a terminal emulator based on [hterm][1] that runs in a minimal, clutter-free [webkitg2gtk][2] webView that covers the entire screen. It is designed to be run on top of [weston compositor][3].
The back-end (terminal-server) runs on nodejs and communicates with hterm via websockets using [substack's shoe][4]. It is desinged to be started via [systemd][5].
This is part of [htmshell][6].
## Installation
### Arch Linux
#### Dependencies
```
pacman -S nodejs weston
```
and from AUR: [webkit2gtk-unstable](https://aur.archlinux.org/packages/webkit2gtk-unstable/)
```
npm i
cp build/node-terminal-server.service /etc/systemd/system/
cp build/html-terminal.service /etc/systemd/system/
systemctl daemon-reload
systemctl start node-terminal-server
```
Make sure your `/etc/systemd/system/weston.service` looks somewhat like mine:
```
[Unit]
Description=weston
RequiresMountsFor=/run
Requires=dbus.service systemd-udevd.service
After=dbus.service systemd-udevd.service
[Service]
Type=notify
NotifyAccess=all
WatchdogSec=20s
ExecStartPre=/bin/mkdir -p /var/run/root/1000
ExecStartPre=/bin/chmod 0700 /var/run/root/1000
ExecStart=/usr/bin/openvt -v -e /usr/bin/weston -- --modules=systemd-notify.so --backend=drm-backend.so --log=/var/log/weston.log
ExecStartPost=/usr/bin/bash -c "env > /var/run/root/1000/environment"
Nice=-20
Environment=XDG_RUNTIME_DIR=/var/run/root/1000
[Install]
WantedBy=multi-user.target
```
# Future Plans
Invent custom [ANSI Escape Sequence][7] to support rendering of HTML snippets inside the terminal window.
[1]: https://github.com/macton/hterm
[2]: https://directory.fsf.org/wiki/Webkit2gtk
[3]: https://github.com/wayland-project/weston
[4]: https://github.com/substack/shoe
[5]: https://en.wikipedia.org/wiki/Systemd
[6]: https://github.com/regular/htmshell
[7]: https://en.wikipedia.org/wiki/ANSI_escape_code