termbeam 0.0.1 → 0.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +118 -31
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -5,28 +5,84 @@
|
|
|
5
5
|
**Beam your terminal to any device**
|
|
6
6
|
|
|
7
7
|
[](https://www.npmjs.com/package/termbeam)
|
|
8
|
+
[](https://github.com/dorlugasigal/TermBeam/actions/workflows/ci.yml)
|
|
8
9
|
[](https://opensource.org/licenses/MIT)
|
|
9
10
|
[](https://nodejs.org)
|
|
10
11
|
|
|
11
12
|
Access your terminal from your phone, tablet, or any browser.
|
|
12
13
|
Multi-session, mobile-optimized, with touch controls.
|
|
13
14
|
|
|
15
|
+
[Getting Started](#-quick-start) · [Screenshots](#-screenshots) · [Documentation](https://dorlugasigal.github.io/TermBeam/) · [Contributing](CONTRIBUTING.md)
|
|
16
|
+
|
|
14
17
|
</div>
|
|
15
18
|
|
|
16
19
|
---
|
|
17
20
|
|
|
21
|
+
## 📸 Screenshots
|
|
22
|
+
|
|
23
|
+
<!--
|
|
24
|
+
To add screenshots:
|
|
25
|
+
1. Run TermBeam: npx termbeam --generate-password
|
|
26
|
+
2. Take screenshots on your phone/browser
|
|
27
|
+
3. Save images to docs/assets/screenshots/
|
|
28
|
+
4. Uncomment the img tags below and update filenames
|
|
29
|
+
|
|
30
|
+
Recommended screenshots:
|
|
31
|
+
- session-manager.png (main screen with session list)
|
|
32
|
+
- terminal.png (active terminal session)
|
|
33
|
+
- folder-browser.png (folder picker sheet)
|
|
34
|
+
- login.png (password login screen)
|
|
35
|
+
- qr-code.png (server startup with QR code in terminal)
|
|
36
|
+
-->
|
|
37
|
+
|
|
38
|
+
<div align="center">
|
|
39
|
+
<table>
|
|
40
|
+
<tr>
|
|
41
|
+
<td align="center"><strong>Session Manager</strong></td>
|
|
42
|
+
<td align="center"><strong>Terminal</strong></td>
|
|
43
|
+
<td align="center"><strong>Folder Browser</strong></td>
|
|
44
|
+
</tr>
|
|
45
|
+
<tr>
|
|
46
|
+
<td>
|
|
47
|
+
|
|
48
|
+
<!--  -->
|
|
49
|
+
|
|
50
|
+
_Manage multiple terminal sessions with swipe-to-delete_
|
|
51
|
+
|
|
52
|
+
</td>
|
|
53
|
+
<td>
|
|
54
|
+
|
|
55
|
+
<!--  -->
|
|
56
|
+
|
|
57
|
+
_Full terminal with touch controls and Nerd Font rendering_
|
|
58
|
+
|
|
59
|
+
</td>
|
|
60
|
+
<td>
|
|
61
|
+
|
|
62
|
+
<!--  -->
|
|
63
|
+
|
|
64
|
+
_Visual directory picker for working directory_
|
|
65
|
+
|
|
66
|
+
</td>
|
|
67
|
+
</tr>
|
|
68
|
+
</table>
|
|
69
|
+
</div>
|
|
70
|
+
|
|
71
|
+
> **💡 Screenshots coming soon!** Run `npx termbeam` and see for yourself.
|
|
72
|
+
|
|
18
73
|
## ✨ Features
|
|
19
74
|
|
|
20
|
-
- 📱 **Mobile-
|
|
75
|
+
- 📱 **Mobile-first UI** — Touch-friendly interface designed for phones and tablets
|
|
21
76
|
- 🖥️ **Multi-session** — Run multiple terminal sessions simultaneously
|
|
22
77
|
- 🔐 **Password auth** — Token-based authentication with rate limiting
|
|
23
|
-
- 📂 **Folder browser** — Visual directory picker
|
|
78
|
+
- 📂 **Folder browser** — Visual directory picker with breadcrumb navigation
|
|
24
79
|
- 👆 **Touch controls** — Arrow keys, Ctrl shortcuts, Tab, Esc via on-screen touch bar
|
|
25
80
|
- 🔤 **Nerd Font support** — Full glyph rendering with JetBrains Mono Nerd Font
|
|
26
81
|
- 📲 **QR code** — Scan to connect instantly from your phone
|
|
27
82
|
- 🌐 **DevTunnel** — Optional public URL for remote access from anywhere
|
|
28
|
-
- 🔍 **
|
|
83
|
+
- 🔍 **Adjustable font size** — Pinch or button zoom for any screen
|
|
29
84
|
- ↔️ **Swipe to delete** — iOS-style session management
|
|
85
|
+
- 🔄 **Smart versioning** — Shows git hash in dev, clean version from npm
|
|
30
86
|
|
|
31
87
|
## 🚀 Quick Start
|
|
32
88
|
|
|
@@ -41,31 +97,41 @@ npm install -g termbeam
|
|
|
41
97
|
termbeam
|
|
42
98
|
```
|
|
43
99
|
|
|
44
|
-
Scan the QR code printed in your terminal, or open the URL on any device.
|
|
100
|
+
That's it. Scan the QR code printed in your terminal, or open the URL on any device.
|
|
45
101
|
|
|
46
|
-
|
|
102
|
+
### With password protection (recommended)
|
|
47
103
|
|
|
48
104
|
```bash
|
|
49
|
-
#
|
|
50
|
-
termbeam
|
|
105
|
+
# Auto-generate a secure password
|
|
106
|
+
termbeam --generate-password
|
|
51
107
|
|
|
52
|
-
#
|
|
108
|
+
# Or set your own
|
|
53
109
|
termbeam --password mysecret
|
|
110
|
+
```
|
|
54
111
|
|
|
55
|
-
|
|
56
|
-
|
|
112
|
+
### Remote access from anywhere
|
|
113
|
+
|
|
114
|
+
```bash
|
|
115
|
+
termbeam --tunnel --generate-password
|
|
116
|
+
```
|
|
117
|
+
|
|
118
|
+
## 📖 Usage
|
|
119
|
+
|
|
120
|
+
```bash
|
|
121
|
+
# Start with your default shell
|
|
122
|
+
termbeam
|
|
57
123
|
|
|
58
124
|
# Use a specific shell
|
|
59
125
|
termbeam /bin/bash
|
|
60
126
|
|
|
61
|
-
# Custom port and listen on all interfaces
|
|
127
|
+
# Custom port and listen on all interfaces (LAN access)
|
|
62
128
|
termbeam --port 8080 --host 0.0.0.0
|
|
63
129
|
|
|
64
130
|
# Public tunnel + password (access from anywhere)
|
|
65
131
|
termbeam --tunnel --generate-password
|
|
66
132
|
```
|
|
67
133
|
|
|
68
|
-
###
|
|
134
|
+
### CLI Options
|
|
69
135
|
|
|
70
136
|
| Flag | Description | Default |
|
|
71
137
|
| --------------------- | ------------------------------- | ----------- |
|
|
@@ -87,37 +153,58 @@ termbeam --tunnel --generate-password
|
|
|
87
153
|
|
|
88
154
|
## 🔒 Security
|
|
89
155
|
|
|
90
|
-
TermBeam is designed for **local network use**.
|
|
156
|
+
TermBeam is designed for **local network use**. Key security features:
|
|
91
157
|
|
|
92
|
-
- **
|
|
93
|
-
-
|
|
94
|
-
-
|
|
95
|
-
-
|
|
96
|
-
- By default, binds to `127.0.0.1` (localhost only)
|
|
97
|
-
- Use `--host 0.0.0.0` explicitly to expose on your LAN
|
|
158
|
+
- 🔑 **Token-based auth** with secure, httpOnly cookies (24-hour expiry)
|
|
159
|
+
- 🛡️ **Rate limiting** on login (5 attempts per minute)
|
|
160
|
+
- 🔒 **Security headers** (X-Frame-Options, X-Content-Type-Options, CSP, etc.)
|
|
161
|
+
- 🏠 **Localhost by default** — requires explicit `--host 0.0.0.0` for LAN access
|
|
98
162
|
|
|
99
|
-
> ⚠️ **
|
|
163
|
+
> ⚠️ **Always use a password when exposing to any network.** See the [Security Guide](https://dorlugasigal.github.io/TermBeam/security/) for production deployment tips.
|
|
100
164
|
|
|
101
|
-
## 🏗️
|
|
165
|
+
## 🏗️ Architecture
|
|
102
166
|
|
|
103
167
|
```
|
|
104
168
|
termbeam/
|
|
105
|
-
├── bin/
|
|
106
|
-
│ └── termbeam.js # CLI entry point
|
|
169
|
+
├── bin/termbeam.js # CLI entry point
|
|
107
170
|
├── src/
|
|
108
|
-
│
|
|
171
|
+
│ ├── server.js # Main orchestrator
|
|
172
|
+
│ ├── cli.js # Argument parsing & help
|
|
173
|
+
│ ├── auth.js # Authentication & rate limiting
|
|
174
|
+
│ ├── sessions.js # PTY session lifecycle
|
|
175
|
+
│ ├── routes.js # Express HTTP routes
|
|
176
|
+
│ ├── websocket.js # WebSocket terminal I/O
|
|
177
|
+
│ ├── tunnel.js # DevTunnel integration
|
|
178
|
+
│ └── version.js # Smart version detection
|
|
109
179
|
├── public/
|
|
110
|
-
│ ├── index.html
|
|
111
|
-
│ └── terminal.html
|
|
112
|
-
├──
|
|
113
|
-
├──
|
|
114
|
-
└──
|
|
180
|
+
│ ├── index.html # Session manager UI (mobile)
|
|
181
|
+
│ └── terminal.html # Terminal UI (xterm.js)
|
|
182
|
+
├── test/ # Unit tests (node:test)
|
|
183
|
+
├── docs/ # MkDocs documentation
|
|
184
|
+
└── .github/workflows/ # CI, Release, Docs deployment
|
|
115
185
|
```
|
|
116
186
|
|
|
187
|
+
See the [Architecture Guide](https://dorlugasigal.github.io/TermBeam/architecture/) for details.
|
|
188
|
+
|
|
189
|
+
## 📚 Documentation
|
|
190
|
+
|
|
191
|
+
Full documentation is available at **[dorlugasigal.github.io/TermBeam](https://dorlugasigal.github.io/TermBeam/)**
|
|
192
|
+
|
|
193
|
+
- [Getting Started](https://dorlugasigal.github.io/TermBeam/getting-started/)
|
|
194
|
+
- [Configuration](https://dorlugasigal.github.io/TermBeam/configuration/)
|
|
195
|
+
- [Security](https://dorlugasigal.github.io/TermBeam/security/)
|
|
196
|
+
- [API Reference](https://dorlugasigal.github.io/TermBeam/api/)
|
|
197
|
+
- [Architecture](https://dorlugasigal.github.io/TermBeam/architecture/)
|
|
198
|
+
|
|
117
199
|
## 🤝 Contributing
|
|
118
200
|
|
|
119
|
-
Contributions are welcome! See [CONTRIBUTING.md](CONTRIBUTING.md) for
|
|
201
|
+
Contributions are welcome! See [CONTRIBUTING.md](CONTRIBUTING.md) for:
|
|
202
|
+
|
|
203
|
+
- Development setup and local workflow
|
|
204
|
+
- Testing guide (Node.js built-in test runner)
|
|
205
|
+
- Commit conventions and PR process
|
|
206
|
+
- Release process (maintainers)
|
|
120
207
|
|
|
121
208
|
## 📄 License
|
|
122
209
|
|
|
123
|
-
[MIT](LICENSE) — made with ❤️
|
|
210
|
+
[MIT](LICENSE) — made with ❤️ by [@dorlugasigal](https://github.com/dorlugasigal)
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "termbeam",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.3",
|
|
4
4
|
"description": "Beam your terminal to any device — mobile-optimized web terminal with multi-session support",
|
|
5
5
|
"main": "src/server.js",
|
|
6
6
|
"bin": {
|
|
@@ -57,7 +57,7 @@
|
|
|
57
57
|
"dependencies": {
|
|
58
58
|
"cookie-parser": "^1.4.7",
|
|
59
59
|
"express": "^5.2.1",
|
|
60
|
-
"node-pty": "
|
|
60
|
+
"node-pty": "1.0.0",
|
|
61
61
|
"qrcode": "^1.5.4",
|
|
62
62
|
"ws": "^8.19.0"
|
|
63
63
|
},
|