-
-
Notifications
You must be signed in to change notification settings - Fork 0
Rebrand to TerKix + PWA, Gemini API improvements, UI & storage refactor #8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
Huynhthuongg
wants to merge
5
commits into
main
Choose a base branch
from
codex/review-and-update-project-setup-bwuljk
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
5 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Some comments aren't visible on the classic Files Changed page.
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,9 +1,14 @@ | ||
| # GEMINI_API_KEY: Required for Gemini AI API calls. | ||
| # AI Studio automatically injects this at runtime from user secrets. | ||
| # Users configure this via the Secrets panel in the AI Studio UI. | ||
| # GEMINI_API_KEY: Required for live Gemini AI API calls. | ||
| # AI Studio can inject this at runtime from user secrets. | ||
| GEMINI_API_KEY="MY_GEMINI_API_KEY" | ||
|
|
||
| # GEMINI_MODEL: Optional model override for the TerKix command endpoint. | ||
| # Defaults to gemini-2.5-flash when omitted. | ||
| GEMINI_MODEL="gemini-2.5-flash" | ||
|
|
||
| # PORT: Optional local/server port. | ||
| PORT="3000" | ||
|
|
||
| # APP_URL: The URL where this applet is hosted. | ||
| # AI Studio automatically injects this at runtime with the Cloud Run service URL. | ||
| # Used for self-referential links, OAuth callbacks, and API endpoints. | ||
| # AI Studio can inject this at runtime with the Cloud Run service URL. | ||
| APP_URL="MY_APP_URL" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,98 @@ | ||
| # TerKix Terminal OS | ||
|
|
||
| TerKix Terminal OS is a Termux-inspired, AI-native development workspace built with React, Vite, Express, and the Google Gemini API. It keeps the TerKix brand front-and-center while providing a terminal-first interface for managing virtual projects, files, agent workflows, deployments, plugins, contacts, and telemetry dashboards. | ||
|
|
||
| ## What this repo contains | ||
|
|
||
| - **React 19 SPA** for the TerKix terminal, workspace explorer, dashboard, plugin hub, contacts manager, and telemetry views. | ||
| - **TerKix logo asset** at `public/terkix-logo.svg` for the favicon, nav rail, cockpit header, and dashboard hero. | ||
| - **Installable PWA shell** via `public/manifest.webmanifest` and `public/sw.js` for app-like launch and offline shell caching. | ||
| - **Terminal productivity upgrades** including persisted command history, arrow-key recall, online/offline status, cache-safe service worker routing, persistent UI preferences, and one-click workspace snapshot export. | ||
| - **Express + Vite server** for local development and production static hosting. | ||
| - **Gemini command API** at `/api/gemini/command` for multi-agent workflow generation with an offline simulator fallback in the UI. | ||
| - **Safe local persistence** for projects, terminal history, active workspace, and command metrics. | ||
|
|
||
| ## Requirements | ||
|
|
||
| - Node.js 22 or newer is recommended. | ||
| - npm 10 or newer. | ||
| - A Gemini API key when you want live AI responses. Without a configured key, the client falls back to the built-in simulator. | ||
|
|
||
| ## Environment setup | ||
|
|
||
| Copy the example environment file and fill in your values: | ||
|
|
||
| ```bash | ||
| cp .env.example .env | ||
| ``` | ||
|
|
||
| Supported variables: | ||
|
|
||
| | Variable | Required | Default | Description | | ||
| | --- | --- | --- | --- | | ||
| | `GEMINI_API_KEY` | Yes for live AI | _none_ | API key used by `@google/genai`. | | ||
| | `GEMINI_MODEL` | No | `gemini-2.5-flash` | Model used by the server command endpoint. | | ||
| | `PORT` | No | `3000` | Port for the Express/Vite server. | | ||
| | `APP_URL` | No | _none_ | Public URL used by hosted environments. | | ||
|
|
||
| ## Development | ||
|
|
||
| Install dependencies: | ||
|
|
||
| ```bash | ||
| npm install | ||
| ``` | ||
|
|
||
| Run the app locally: | ||
|
|
||
| ```bash | ||
| npm run dev | ||
| ``` | ||
|
|
||
| Open `http://localhost:3000`. | ||
|
|
||
| ## Quality checks | ||
|
|
||
| Run TypeScript validation: | ||
|
|
||
| ```bash | ||
| npm run typecheck | ||
| ``` | ||
|
|
||
| Run the full production build: | ||
|
|
||
| ```bash | ||
| npm run build | ||
| ``` | ||
|
|
||
| Start the production build: | ||
|
|
||
| ```bash | ||
| npm start | ||
| ``` | ||
|
|
||
| Check server health when the app is running: | ||
|
|
||
| ```bash | ||
| curl http://localhost:3000/api/health | ||
| ``` | ||
|
|
||
| ## Project structure | ||
|
|
||
| ```text | ||
| . | ||
| ├── server.ts # Express server and Gemini command endpoint | ||
| ├── src/App.tsx # Main TerKix UI shell and workspace logic | ||
| ├── src/components/ # Dashboard, project, plugin, contact, and chart modules | ||
| ├── src/data/presets.ts # Default virtual projects and sample workspace files | ||
| ├── src/types.ts # Shared domain types | ||
| ├── src/utils/storage.ts # Defensive localStorage helpers | ||
| └── public/ # TerKix logo, web manifest, and service worker | ||
| ``` | ||
|
|
||
| ## Notes for contributors | ||
|
|
||
| - Keep generated workspace file paths under `workspace/project/...` so the TerKix virtual file explorer can mount them correctly. | ||
| - Keep dependencies that are only needed for builds or tooling in `devDependencies`. | ||
| - Do not commit `.env` files or real API keys. | ||
| - Run `npm run typecheck` and `npm run build` before opening a pull request. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,6 +1,10 @@ | ||
| { | ||
| "name": "RKix Terminal OS", | ||
| "description": "AI-native terminal-based software development environment with autonomous planner, builder, designer, debugger, and deployer agents.", | ||
| "requestFramePermissions": [], | ||
| "majorCapabilities": ["MAJOR_CAPABILITY_SERVER_SIDE_GEMINI_API"] | ||
| "name": "TerKix Terminal OS", | ||
| "description": "AI-native terminal-based software development environment with autonomous planner, builder, designer, debugger, deployer, plugin, contact, and telemetry agents.", | ||
| "requestFramePermissions": [ | ||
| "microphone" | ||
| ], | ||
| "majorCapabilities": [ | ||
| "MAJOR_CAPABILITY_SERVER_SIDE_GEMINI_API" | ||
| ] | ||
| } |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.