{"id":49552670,"url":"https://github.com/luohino/nexusvault","last_synced_at":"2026-05-03T00:04:24.544Z","repository":{"id":353823620,"uuid":"1219366039","full_name":"Luohino/NexusVault","owner":"Luohino","description":"NexusVault is a modern, high-performance developer platform for hosting repositories, browsing code, and collaborating on anomalies.","archived":false,"fork":false,"pushed_at":"2026-04-25T17:49:02.000Z","size":1841,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2026-04-25T19:23:39.438Z","etag":null,"topics":["contributions-welcome","open-source","testing"],"latest_commit_sha":null,"homepage":"https://nexusvault-luohino.vercel.app/","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"agpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Luohino.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGE_MANAGEMENT.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"SECURITY.md","support":"SUPPORT.md","governance":"GOVERNANCE_CHARTER.md","roadmap":"ROADMAP.md","authors":"AUTHORS.md","dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":"CONTRIBUTOR_LICENSE_AGREEMENT.md"}},"created_at":"2026-04-23T20:00:21.000Z","updated_at":"2026-04-25T17:49:05.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/Luohino/NexusVault","commit_stats":null,"previous_names":["luohino/nexusvault"],"tags_count":null,"template":false,"template_full_name":null,"purl":"pkg:github/Luohino/NexusVault","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Luohino%2FNexusVault","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Luohino%2FNexusVault/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Luohino%2FNexusVault/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Luohino%2FNexusVault/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Luohino","download_url":"https://codeload.github.com/Luohino/NexusVault/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Luohino%2FNexusVault/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32553693,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-02T22:28:24.418Z","status":"ssl_error","status_checked_at":"2026-05-02T22:28:14.225Z","response_time":132,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["contributions-welcome","open-source","testing"],"created_at":"2026-05-03T00:04:20.042Z","updated_at":"2026-05-03T00:04:24.504Z","avatar_url":"https://github.com/Luohino.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cp align=\"center\"\u003e\n  \u003cimg src=\"Screenshots/removedbg.png\" width=\"400\" alt=\"NexusVault Logo\"\u003e\n\u003c/p\u003e\n\n# NexusVault\n\nNexusVault is a high-performance, decentralized-first developer platform optimized for repository hosting, code intelligence, and high-concurrency data management. It provides a seamless bridge between a specialized Lua-driven IDE and a robust TypeScript-powered server cluster.\n\n---\n\n## Technical Showcase\n\nThe following interfaces represent the core operational environment of NexusVault, highlighting the direct integration between local development and cloud-scale synchronization.\n\n### Repository Control Center\n| Interface Segment | Operational Context |\n| :--- | :--- |\n| **Hero section** | ![Dashboard](Screenshots/1.jpeg) |\n| **Profile page** | ![Code Viewer](Screenshots/2.jpeg) |\n| **Home Page** | ![Issues](Screenshots/3.jpeg) |\n| **Repo** | ![Issues](Screenshots/4.jpeg) |\n| **Settings** | ![Issues](Screenshots/5.jpeg) |\n\n### IDE Hub (NV-Engine)\n| IDE View | System Integration |\n| :--- | :--- |\n| **IDE** | ![IDE Terminal](Screenshots/ide1.png) |\n| **Code Ediotr** | ![IDE Navigator](Screenshots/ide2.png) |\n| **NexusTerminal** | ![IDE Sync](Screenshots/ide3.png) |\n\n---\n\n##  System Architecture\n\nNexusVault operates on a multi-layered architecture designed to eliminate bottlenecks and ensure horizontal scalability.\n\n### Core Request Lifecycle\n```mermaid\ngraph TD\n    User([Developer / NexuVault]) --\u003e LB{Traffic Controller}\n    LB --\u003e Cluster[Node.js Cluster Engine]\n    Cluster --\u003e Worker1[Worker Process 1]\n    Cluster --\u003e Worker2[Worker Process 2]\n    Cluster --\u003e WorkerN[Worker Process N]\n    \n    Worker1 --\u003e Security{CSP \u0026 JWT Validation}\n    Security --\u003e API[Nexus API Engine]\n    \n    API --\u003e Splitter{Read/Write Router}\n    Splitter -- \"Mutations\" --\u003e PrimaryDB[(Primary DB)]\n    Splitter -- \"Queries\" --\u003e ReadReplica[(Read Replica)]\n    \n    API --\u003e RedisCache[(Redis Cache)]\n    API --\u003e BlobStore[(S3-Compatible Storage)]\n```\n\n---\n\n##  Under the Hood: IDE-to-Server Integration\n\nNexusVault is unique in its \"Local-First\" approach, where the IDE handles the heavy lifting of delta tracking and metadata management.\n\n### Lua API Communication (nv.lua)\nThe IDE uses a custom-built Lua plugin (`nv.lua`) to perform asynchronous, authenticated operations against the NexusVault API using system-level CURL.\n\n```lua\n-- Example: Core API POST handler in nv.lua\nlocal function run_json_post(url, token, payload, payload_is_inline)\n  local curl = PLATFORM == \"Windows\" and \"curl.exe\" or \"curl\"\n  local args = {\n    curl, \"-sS\", \"-X\", \"POST\", url,\n    \"-H\", \"Content-Type: application/json\",\n  }\n  if payload_is_inline then\n    table.insert(args, \"-d\")\n    table.insert(args, payload)\n  else\n    table.insert(args, \"--data-binary\")\n    table.insert(args, \"@\" .. payload)\n  end\n  if token and token ~= \"\" then\n    table.insert(args, \"-H\")\n    table.insert(args, \"Authorization: Bearer \" .. token)\n  end\n  -- Non-blocking process execution\n  local proc, err = process.start(args, {\n    stdout = process.REDIRECT_PIPE,\n    stderr = process.REDIRECT_PIPE\n  })\n  return proc:wait(300)\nend\n```\n\n### Push Lifecycle Transaction\n```mermaid\nsequenceDiagram\n    participant IDE as NexuVault (nv.lua)\n    participant Local as .nv Metadata\n    participant API as Server (api.ts)\n    participant DB as Postgres (Drizzle)\n\n    IDE-\u003e\u003eLocal: Scan Workspace\n    Local-\u003e\u003eIDE: Compare with HEAD_state\n    IDE-\u003e\u003eIDE: Compress Changed Deltas\n    IDE-\u003e\u003eAPI: POST /api/repos/:owner/:repo/push\n    API-\u003e\u003eAPI: Validate Auth \u0026 Payload Limits\n    API-\u003e\u003eDB: Open Transaction\n    DB-\u003e\u003eDB: Update files \u0026 create versions\n    DB--\u003e\u003eAPI: Commit Success\n    API--\u003e\u003eIDE: 200 OK (New Commit ID)\n    IDE-\u003e\u003eLocal: Update HEAD_state\n```\n\n---\n\n## Core Technical Stack\n\n| Layer | Technology | Operational Role |\n| :--- | :--- | :--- |\n| **Frontend Framework** | React 18 | Real-time UI rendering and dynamic code browsing. |\n| **Build Tooling** | Vite | Ultra-fast development and optimized production assets. |\n| **Styling** | Tailwind CSS | Consistent Neo-Brutalist design tokens. |\n| **Server Engine** | Node.js / TS | High-concurrency cluster with worker process management. |\n| **Data Backbone** | PostgreSQL | Source of truth for repositories, commits, and users. |\n| **Speed Layer** | Redis | High-speed cache for metadata and session stability. |\n| **IDE Engine** | NexuVault (Lua) | Lightweight, C-powered editor for local-first operations. |\n| **Identity** | Clerk | Secure user authentication and session management. |\n\n---\n\n##  Architecture Deep Dive\n\n### Local Metadata (.nv Directory)\nThe `.nv` directory is the core of the NexusVault local engine. It contains:\n- `config`: Stores remote URLs and authentication tokens.\n- `HEAD_state`: A high-performance flat file mapping every tracked file to its last-known server timestamp.\n- `HEAD`: The current branch reference.\n\n### Data Modeling \u0026 Relations\nNexusVault uses a structured relational schema to maintain the integrity of code snapshots and version history.\n\n| Entity | System Role | Relationship |\n| :--- | :--- | :--- |\n| **Users** | Operators | Owns multiple repositories; authors commits and issues. |\n| **Repositories** | Project Containers | Linked to an owner; contains files, commits, and metadata. |\n| **Commits** | State Snapshots | Belongs to a repository; links to multiple file versions. |\n| **Files** | Current Buffer | The latest state of a file in a repository. |\n| **File Versions** | Delta History | Immutable snapshots of files linked to specific commit IDs. |\n\n### High-Concurrency Deployment\nThe server uses a **Master/Worker Clustering Model** to utilize 100% of the host's CPU threads.\n- **Read/Write Splitting**: Mutation traffic is pinned to the primary database, while search and listing operations are distributed across read-replicas.\n- **MIME Detection**: The `GET /api/repos/.../raw/` API provides automatic content-type headers for images and code, enabling perfect README rendering.\n\n---\n\n##  Security \u0026 Performance Engineering\n\nNexusVault implements several layers of hardening to ensure stability under high load and protection against common attack vectors.\n\n### SQL Injection Protection (Pattern Escaping)\nAll search-based queries utilize a specialized escaping utility to prevent `ILIKE` pattern-based injection attacks.\n\n```typescript\n// src/server/validation.ts\nexport function escapeLikePattern(pattern: string): string {\n  // Escapes % and _ which are special characters in SQL LIKE/ILIKE patterns\n  return pattern.replace(/[%_]/g, (match) =\u003e `\\\\${match}`);\n}\n```\n\n### Network \u0026 Load Optimization\nTo minimize latency and maximize throughput, the following middlewares are integrated into the core application:\n\n| Optimization | Implementation | Rationale |\n| :--- | :--- | :--- |\n| **Gzip Compression** | `compression()` middleware | Reduces API payload size by up to 70% for large file snapshots. |\n| **Static Caching** | `maxAge: '1d'` headers | Offloads repeat asset requests to the browser cache for 24 hours. |\n| **Rate Limiting** | `express-rate-limit` | Protects expensive auth and search routes from brute-force/DoS attempts. |\n\n---\n\n## Technical CLI Reference\n\n| Command | Action | System Impact |\n| :--- | :--- | :--- |\n| `nv init` | Initialization | Generates the `.nv` directory and initial state tracking. |\n| `nv login` | Authentication | Negotiates the CLI browser handshake for a signed JWT. |\n| `nv status` | Intelligence | Computes local vs remote deltas using `HEAD_state`. |\n| `nv push` | Synchronization | Atomic transmission of changes to the server transaction layer. |\n| `nv remote` | Configuration | Manages the `remote.\u003cname\u003e.url` values in the local config. |\n\n---\n\n\u003cp align=\"center\"\u003e\n  \u003cb\u003eHigh-Fidelity Engineering. Zero Latency.\u003c/b\u003e\u003cbr\u003e\n  NexusVault Development Command\n\u003c/p\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fluohino%2Fnexusvault","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fluohino%2Fnexusvault","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fluohino%2Fnexusvault/lists"}