own-term 0.1.0

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.
Files changed (54) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +353 -0
  3. package/bin/cli.d.ts +3 -0
  4. package/bin/cli.d.ts.map +1 -0
  5. package/bin/cli.js +29 -0
  6. package/bin/cli.js.map +1 -0
  7. package/bin/commands/index.d.ts +3 -0
  8. package/bin/commands/index.d.ts.map +1 -0
  9. package/bin/commands/index.js +390 -0
  10. package/bin/commands/index.js.map +1 -0
  11. package/bin/config.d.ts +10 -0
  12. package/bin/config.d.ts.map +1 -0
  13. package/bin/config.js +160 -0
  14. package/bin/config.js.map +1 -0
  15. package/bin/plugins/loader.d.ts +11 -0
  16. package/bin/plugins/loader.d.ts.map +1 -0
  17. package/bin/plugins/loader.js +89 -0
  18. package/bin/plugins/loader.js.map +1 -0
  19. package/bin/plugins/plugin_api.d.ts +15 -0
  20. package/bin/plugins/plugin_api.d.ts.map +1 -0
  21. package/bin/plugins/plugin_api.js +27 -0
  22. package/bin/plugins/plugin_api.js.map +1 -0
  23. package/bin/render/effects.d.ts +22 -0
  24. package/bin/render/effects.d.ts.map +1 -0
  25. package/bin/render/effects.js +57 -0
  26. package/bin/render/effects.js.map +1 -0
  27. package/bin/render/renderer.d.ts +71 -0
  28. package/bin/render/renderer.d.ts.map +1 -0
  29. package/bin/render/renderer.js +175 -0
  30. package/bin/render/renderer.js.map +1 -0
  31. package/bin/shell/engine.d.ts +53 -0
  32. package/bin/shell/engine.d.ts.map +1 -0
  33. package/bin/shell/engine.js +242 -0
  34. package/bin/shell/engine.js.map +1 -0
  35. package/bin/shell/router.d.ts +27 -0
  36. package/bin/shell/router.d.ts.map +1 -0
  37. package/bin/shell/router.js +80 -0
  38. package/bin/shell/router.js.map +1 -0
  39. package/bin/shell/welcome.d.ts +4 -0
  40. package/bin/shell/welcome.d.ts.map +1 -0
  41. package/bin/shell/welcome.js +162 -0
  42. package/bin/shell/welcome.js.map +1 -0
  43. package/bin/themes/default.d.ts +10 -0
  44. package/bin/themes/default.d.ts.map +1 -0
  45. package/bin/themes/default.js +61 -0
  46. package/bin/themes/default.js.map +1 -0
  47. package/bin/types.d.ts +107 -0
  48. package/bin/types.d.ts.map +1 -0
  49. package/bin/types.js +6 -0
  50. package/bin/types.js.map +1 -0
  51. package/package.json +70 -0
  52. package/templates/default/termfolio.config.ts +37 -0
  53. package/templates/hacker/termfolio.config.ts +34 -0
  54. package/templates/minimal/termfolio.config.ts +23 -0
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Own-term Contributors
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md ADDED
@@ -0,0 +1,353 @@
1
+ # Own-term 🚀
2
+
3
+ <div align="center">
4
+
5
+ ![Own-term Banner](./src/assets/banner.png)
6
+
7
+ **Create a beautiful, interactive terminal portfolio — installable via `npx` or `npm i -g`**
8
+
9
+ [![npm version](https://badge.fury.io/js/own-term.svg)](https://www.npmjs.com/package/own-term)
10
+ [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
11
+ [![PRs Welcome](https://img.shields.io/badge/PRs-welcome-brightgreen.svg)](CONTRIBUTING.md)
12
+
13
+ [Features](#-features) • [Quick Start](#-quick-start) • [Documentation](#-documentation) • [Contributing](#-contributing)
14
+
15
+ </div>
16
+
17
+ ---
18
+
19
+ ## 🎯 What is Own-term?
20
+
21
+ **Own-term** is a powerful, reusable framework for creating beautiful terminal portfolios.
22
+ Not just a single person's portfolio — it's a complete framework that lets anyone create their own interactive terminal experience.
23
+
24
+ ### Why Own-term?
25
+
26
+ - 🎨 **Beautiful by default** - Stunning themes, gradients, and ASCII art
27
+ - 🔌 **Plugin system** - Extend with custom commands and features
28
+ - 🎭 **Multiple themes** - 6 built-in themes (dark, light, hacker, neo, dracula, nordic)
29
+ - 💻 **Dynamic prompts** - 5 configurable prompt styles (git, time, dashboard, minimal, cyberpunk)
30
+ - ⚡ **Zero config** - Works out of the box, customize when you want
31
+ - 📦 **Easy to use** - Run with `npx` or install globally
32
+ - 🛠️ **Developer friendly** - TypeScript, well-documented, tested
33
+
34
+ ---
35
+
36
+ ## ✨ Features
37
+
38
+ ### Core Features
39
+
40
+ - ✅ Interactive shell with commands: `about`, `projects`, `skills`, `contact`, `resume`, `theme`, `help`
41
+ - ✅ Config file (`termfolio.config.ts`) for easy customization
42
+ - ✅ Beautiful ASCII logo with Claude-style gradient (orange → pink → purple)
43
+ - ✅ 6 color themes with gradient support
44
+ - ✅ 5 dynamic prompt styles (git-style, time-based, dashboard, minimal, cyberpunk)
45
+ - ✅ Context-aware prompts (changes based on current command)
46
+ - ✅ Animated boot sequence and welcome screen
47
+ - ✅ Installable via npm / runnable via npx
48
+
49
+ ### Advanced Features
50
+
51
+ - 🔌 Plugin system for custom commands
52
+ - 🎨 Theme system with 6 built-in themes
53
+ - 📊 Beautiful rendering components (tables, progress bars, cards)
54
+ - 🧪 Full test coverage
55
+ - 🚀 CI/CD pipeline with GitHub Actions
56
+ - 📚 Comprehensive documentation
57
+
58
+ ---
59
+
60
+ ## 🚀 Quick Start
61
+
62
+ ### Try it instantly
63
+
64
+ ```bash
65
+ npx own-term
66
+ ```
67
+
68
+ ### Install globally
69
+
70
+ ```bash
71
+ npm install -g own-term
72
+ own-term
73
+ ```
74
+
75
+ ### Create your own portfolio
76
+
77
+ 1. **Create a config file** (`termfolio.config.ts`):
78
+
79
+ ```typescript
80
+ export default {
81
+ name: "Your Name",
82
+ title: "Your Title",
83
+ about: "A brief description about yourself",
84
+ theme: "dark", // dark, light, hacker, neo, dracula, nordic
85
+ promptStyle: "dashboard", // git, time, dashboard, minimal, cyberpunk
86
+ links: {
87
+ github: "https://github.com/yourusername",
88
+ linkedin: "https://linkedin.com/in/yourusername",
89
+ email: "you@example.com"
90
+ },
91
+ projects: [
92
+ {
93
+ name: "Awesome Project",
94
+ desc: "Description of your project",
95
+ repo: "https://github.com/yourusername/project",
96
+ tags: ["javascript", "react"],
97
+ status: "active" // active, wip, archived
98
+ }
99
+ ],
100
+ skills: {
101
+ languages: [
102
+ { name: "JavaScript", level: 90 }, // with progress bar
103
+ "Python" // or simple string
104
+ ],
105
+ frameworks: ["React", "Node.js"],
106
+ tools: ["Git", "Docker", "VS Code"]
107
+ },
108
+ resume: "https://yourwebsite.com/resume.pdf"
109
+ };
110
+ ```
111
+
112
+ 2. **Run your portfolio**:
113
+
114
+ ```bash
115
+ npx own-term --config=./termfolio.config.ts
116
+ ```
117
+
118
+ ---
119
+
120
+ ## 📖 Documentation
121
+
122
+ ### Available Commands
123
+
124
+ | Command | Description |
125
+ |---------|------------|
126
+ | `about` | Learn about the person |
127
+ | `projects` | Browse projects (interactive picker) |
128
+ | `skills` | See skills with progress bars |
129
+ | `contact` | Get contact information |
130
+ | `resume` | Open resume (if configured) |
131
+ | `theme [name]` | Change theme (or see theme gallery) |
132
+ | `clear` | Clear terminal and show welcome screen |
133
+ | `help` | Show available commands |
134
+ | `exit` | Exit the portfolio |
135
+ | `open [service]` | Quick open links (e.g., `open github`) |
136
+
137
+ ### Themes
138
+
139
+ Built-in themes:
140
+
141
+ - **dark** (default) - Modern dark theme with cyan/purple accents
142
+ - **light** - Clean light theme
143
+ - **hacker** - Matrix-style green terminal
144
+ - **neo** - Neon pink & cyan
145
+ - **dracula** - Classic Dracula palette
146
+ - **nordic** - Muted Nordic tones
147
+
148
+ Change theme in config:
149
+ ```typescript
150
+ theme: "dracula"
151
+ ```
152
+
153
+ Or interactively:
154
+ ```bash
155
+ theme dracula
156
+ ```
157
+
158
+ ### Prompt Styles
159
+
160
+ Choose from 5 dynamic prompt styles:
161
+
162
+ 1. **git** - Git-style: `user@termfolio ~/project (context) ❯`
163
+ 2. **time** - Time-based: `[14:23] 📧 project:context ▶`
164
+ 3. **dashboard** (default) - Full info with time, context, counter
165
+ 4. **minimal** - Zsh-style: `◆ ~/project ➜`
166
+ 5. **cyberpunk** - Hacker aesthetic: `█ root@project [context] $`
167
+
168
+ Configure in `termfolio.config.ts`:
169
+ ```typescript
170
+ promptStyle: "time"
171
+ ```
172
+
173
+ Prompts are **context-aware** and change based on your current command!
174
+
175
+ ### Skills Configuration
176
+
177
+ Two formats supported:
178
+
179
+ ```typescript
180
+ skills: {
181
+ // With progress bars (0-100)
182
+ languages: [
183
+ { name: "TypeScript", level: 92 },
184
+ { name: "JavaScript", level: 95 }
185
+ ],
186
+
187
+ // Simple pills
188
+ tools: ["Git", "Docker", "VS Code"]
189
+ }
190
+ ```
191
+
192
+ ### Example Configurations
193
+
194
+ See [templates/](./templates/) for complete examples:
195
+
196
+ - [Default](./templates/default/termfolio.config.ts) - Standard professional template
197
+ - [Hacker](./templates/hacker/termfolio.config.ts) - Security researcher theme
198
+ - [Minimal](./templates/minimal/termfolio.config.ts) - Bare essentials
199
+
200
+ ---
201
+
202
+ ## 🔌 Plugin Development
203
+
204
+ Create custom plugins to extend functionality:
205
+
206
+ ```typescript
207
+ import { createPlugin } from "own-term";
208
+
209
+ export default createPlugin("my-plugin", "1.0.0", (api) => {
210
+ api.registerCommand("custom", "My custom command", async (args) => {
211
+ api.render.header("Custom Command");
212
+ api.render.text("Hello from my plugin!");
213
+
214
+ // Access config
215
+ const config = api.getConfig();
216
+ api.render.info(`User: ${config.name}`);
217
+
218
+ // Use theme colors
219
+ api.render.success("Command executed!");
220
+ });
221
+ });
222
+ ```
223
+
224
+ Add plugins to your config:
225
+
226
+ ```typescript
227
+ export default {
228
+ // ... other config
229
+ plugins: ["@username/my-plugin-package"]
230
+ };
231
+ ```
232
+
233
+ ---
234
+
235
+ ## 🛠️ Development
236
+
237
+ ### Prerequisites
238
+
239
+ - Node.js 18+
240
+ - npm or yarn
241
+
242
+ ### Setup
243
+
244
+ ```bash
245
+ # Clone the repository
246
+ git clone https://github.com/Biki-dev/own-term.git
247
+ cd own-term
248
+
249
+ # Install dependencies
250
+ npm install
251
+
252
+ # Run in development mode
253
+ npm run dev
254
+
255
+ # Build
256
+ npm run build
257
+
258
+ # Run tests
259
+ npm test
260
+
261
+ # Lint
262
+ npm run lint
263
+
264
+ # Format code
265
+ npm run format
266
+ ```
267
+
268
+ ### Project Structure
269
+
270
+ ```
271
+ own-term/
272
+ ├── src/
273
+ │ ├── cli.ts # Entry point
274
+ │ ├── config.ts # Config loader
275
+ │ ├── types.ts # TypeScript definitions
276
+ │ ├── shell/
277
+ │ │ ├── engine.ts # Shell engine with 5 prompt styles
278
+ │ │ ├── router.ts # Command router
279
+ │ │ └── welcome.ts # Welcome screen with gradient logo
280
+ │ ├── render/
281
+ │ │ ├── renderer.ts # Rendering components
282
+ │ │ └── effects.ts # Typewriter effects
283
+ │ ├── commands/
284
+ │ │ └── index.ts # Core commands
285
+ │ ├── plugins/
286
+ │ │ ├── loader.ts # Plugin loading system
287
+ │ │ └── plugin_api.ts # Plugin API
288
+ │ └── themes/
289
+ │ └── default.ts # 6 theme definitions
290
+ ├── templates/ # Starter templates
291
+ ├── tests/ # Test files
292
+ └── bin/ # Compiled output
293
+ ```
294
+
295
+ ---
296
+
297
+ ## 🤝 Contributing
298
+
299
+ We love contributions! Please read our [Contributing Guide](CONTRIBUTING.md) to get started.
300
+
301
+ ### Ways to Contribute
302
+
303
+ - 🐛 Report bugs via [Issues](https://github.com/Biki-dev/own-term/issues)
304
+ - 💡 Suggest features
305
+ - 📝 Improve documentation
306
+ - 🎨 Create new themes
307
+ - 🔌 Build plugins
308
+ - ✅ Write tests
309
+ - 🌍 Add translations
310
+
311
+ ### Development Workflow
312
+
313
+ 1. Fork the repo
314
+ 2. Create a feature branch: `git checkout -b feature/my-feature`
315
+ 3. Make your changes
316
+ 4. Run tests: `npm test`
317
+ 5. Run linter: `npm run lint`
318
+ 6. Commit with conventional commits: `feat(prompt): add new style`
319
+ 7. Push and create a Pull Request
320
+
321
+ ---
322
+
323
+ ## 📄 License
324
+
325
+ MIT © [Biki-dev](https://github.com/Biki-dev)
326
+
327
+ See [LICENSE](LICENSE) for details.
328
+
329
+ ---
330
+
331
+ ## 🌟 Showcase
332
+
333
+ Using Own-term for your portfolio? Add it here!
334
+
335
+ - Submit a PR to add your portfolio to this list
336
+
337
+ ---
338
+
339
+ ## 🙏 Acknowledgments
340
+
341
+ - Inspired by terminal-based portfolio projects
342
+ - Built with [chalk](https://github.com/chalk/chalk), [inquirer](https://github.com/SBoudrias/Inquirer.js), [boxen](https://github.com/sindresorhus/boxen)
343
+ - Logo gradient inspired by [Claude.ai](https://claude.ai)
344
+
345
+ ---
346
+
347
+ <div align="center">
348
+
349
+ **Made for developers**
350
+
351
+ [⬆ Back to top](#own-term-)
352
+
353
+ </div>
package/bin/cli.d.ts ADDED
@@ -0,0 +1,3 @@
1
+ #!/usr/bin/env node
2
+ export {};
3
+ //# sourceMappingURL=cli.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cli.d.ts","sourceRoot":"","sources":["../src/cli.ts"],"names":[],"mappings":""}
package/bin/cli.js ADDED
@@ -0,0 +1,29 @@
1
+ #!/usr/bin/env node
2
+ "use strict";
3
+ Object.defineProperty(exports, "__esModule", { value: true });
4
+ const config_1 = require("./config");
5
+ const engine_1 = require("./shell/engine");
6
+ /**
7
+ * Main CLI entry point
8
+ */
9
+ async function main() {
10
+ try {
11
+ // Parse command line arguments
12
+ const args = process.argv.slice(2);
13
+ const configPath = args.find((arg) => arg.startsWith("--config="))?.split("=")[1];
14
+ // Load configuration
15
+ const config = await (0, config_1.loadConfig)(configPath);
16
+ // Create and initialize shell
17
+ const shell = new engine_1.ShellEngine(config);
18
+ shell.setupSignalHandlers();
19
+ await shell.init();
20
+ await shell.start();
21
+ }
22
+ catch (error) {
23
+ console.error("Fatal error:", error);
24
+ process.exit(1);
25
+ }
26
+ }
27
+ // Run the CLI
28
+ main();
29
+ //# sourceMappingURL=cli.js.map
package/bin/cli.js.map ADDED
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cli.js","sourceRoot":"","sources":["../src/cli.ts"],"names":[],"mappings":";;;AAEA,qCAAsC;AACtC,2CAA6C;AAE7C;;GAEG;AACH,KAAK,UAAU,IAAI;IACf,IAAI,CAAC;QACD,+BAA+B;QAC/B,MAAM,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC;QACnC,MAAM,UAAU,GAAG,IAAI,CAAC,IAAI,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,CAAC,UAAU,CAAC,WAAW,CAAC,CAAC,EAAE,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC;QAElF,qBAAqB;QACrB,MAAM,MAAM,GAAG,MAAM,IAAA,mBAAU,EAAC,UAAU,CAAC,CAAC;QAE5C,8BAA8B;QAC9B,MAAM,KAAK,GAAG,IAAI,oBAAW,CAAC,MAAM,CAAC,CAAC;QACtC,KAAK,CAAC,mBAAmB,EAAE,CAAC;QAE5B,MAAM,KAAK,CAAC,IAAI,EAAE,CAAC;QACnB,MAAM,KAAK,CAAC,KAAK,EAAE,CAAC;IACxB,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC;QACb,OAAO,CAAC,KAAK,CAAC,cAAc,EAAE,KAAK,CAAC,CAAC;QACrC,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;IACpB,CAAC;AACL,CAAC;AAED,cAAc;AACd,IAAI,EAAE,CAAC"}
@@ -0,0 +1,3 @@
1
+ import { CommandHandler, CommandContext, TermfolioConfig } from "../types";
2
+ export declare function registerCoreCommands(config: TermfolioConfig, context: CommandContext): Record<string, CommandHandler>;
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/commands/index.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,cAAc,EAAE,cAAc,EAAE,eAAe,EAAE,MAAM,UAAU,CAAC;AAyB3E,wBAAgB,oBAAoB,CAClC,MAAM,EAAE,eAAe,EACvB,OAAO,EAAE,cAAc,GACtB,MAAM,CAAC,MAAM,EAAE,cAAc,CAAC,CA4ahC"}