{"id":38981685,"url":"https://github.com/krypciak/cc-vim","last_synced_at":"2026-01-17T16:54:47.276Z","repository":{"id":189416957,"uuid":"680638410","full_name":"krypciak/cc-vim","owner":"krypciak","description":"CrossCode in-game vim-like command mode","archived":false,"fork":false,"pushed_at":"2025-08-17T11:54:33.000Z","size":143,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-08-17T13:25:38.192Z","etag":null,"topics":["crosscode","developer-tool","mod"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/krypciak.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2023-08-19T22:33:57.000Z","updated_at":"2025-08-17T11:54:37.000Z","dependencies_parsed_at":"2024-05-03T19:44:42.322Z","dependency_job_id":"f69fec84-02ef-4c76-b5f2-ac768d731153","html_url":"https://github.com/krypciak/cc-vim","commit_stats":null,"previous_names":["krypciak/cc-vim"],"tags_count":21,"template":false,"template_full_name":null,"purl":"pkg:github/krypciak/cc-vim","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/krypciak%2Fcc-vim","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/krypciak%2Fcc-vim/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/krypciak%2Fcc-vim/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/krypciak%2Fcc-vim/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/krypciak","download_url":"https://codeload.github.com/krypciak/cc-vim/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/krypciak%2Fcc-vim/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28511876,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-17T13:38:16.342Z","status":"ssl_error","status_checked_at":"2026-01-17T13:37:44.060Z","response_time":85,"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":["crosscode","developer-tool","mod"],"created_at":"2026-01-17T16:54:46.600Z","updated_at":"2026-01-17T16:54:47.257Z","avatar_url":"https://github.com/krypciak.png","language":"TypeScript","readme":"\u003c!-- markdownlint-disable MD013 MD024 MD001 MD045 --\u003e\n\n[![CCModManager badge](https://raw.githubusercontent.com/CCDirectLink/CCModManager/refs/heads/master/icon/badge.png)](https://github.com/CCDirectLink/CCModManager)\n\n[![](https://tokei.rs/b1/github/krypciak/cc-vim?type=typescript\u0026label=TypeScript\u0026style=flat)](https://github.com/krypciak/cc-vim)\n\nhttps://github.com/krypciak/cc-vim/assets/115574014/76d5fe28-e5b3-4570-88b9-a6e4515fac60\n\nThe menu is openable with `;` by default  \nMove through command history with `↑` arrows `↓`  \nSee [alias list](ALIASES.md)\n\n## Dependencies\n\n1. [input-api](https://github.com/CCDirectLink/input-api)\n\n[![Realeses](https://github.com/CCDirectLink/organization/blob/master/assets/badges/releases%402x.png)](https://github.com/krypciak/cc-vim/releases/)\n\n# For Developers\n\n- [Executing from the CLI](#executing-from-the-cli)\n- [Types](#types)\n- [Examples](#examples) - [Simplest](#simplest-alias)\n    - [With arguments](#examples-with-arguments)\n- [TypeScript support](#typescript-support)\n- [JavaScript support](#javascript-support)\n- [Contribution](#contribution)\n- [Building](#building)\n\nInclude the mod as a hard dependency in `ccmod.json` or use:\n\n```ts\nif (window.vim) {\n\t... your aliases ...\n}\n```\n\n## Executing from the CLI\n\nFor example:\n\n```ts\nvim.executeString('title-screen')\nvim.executeString('load-preset: 0')\n```\n\n## Types\n\n```ts\ninterface Alias {\n    origin: string /* namespace */\n    name: string /* command name */\n    description: string\n    command: (...args: string[]) =\u003e void /* command to execute */\n    condition: /* if the alias appears in the menu, updated every time the menu is shown */\n        | 'ingame' /* can only be used in-game */\n        | 'global' /* can be used anywhere */\n        | 'titlemenu' /* can only be used in the title menu */\n        | ((ingame: boolean) =\u003e boolean) /* custom function */\n\n    arguments: AliasArguemnt[] /* see below, argument length is not enforced */\n\n    keys: string[] /* what do include in the fuzzy search */\n    display: string[] /* what to display */\n}\ninterface AliasArguemnt {\n    type: string /* value type, doesnt really do anything, not enforced */\n    possibleArguments?: /* possible types, not enforced */\n        AliasArguemntEntry[] /* hard-coded values */ | (() =\u003e AliasArguemntEntry[]) /* custom function, run every time the possible values list is shown */\n    description: string\n}\ninterface AliasArguemntEntry {\n    value: string /* what will be passed to the function */\n\n    keys: string[] /* what do include in the fuzzy search */\n    display: string[] /* what to display */\n}\n```\n\n## Examples\n\n### Simplest alias\n\n```ts\n//           namespace  command-name  description       condition function\nvim.addAlias('cc-vim', 'reload',      'Reload the game, 'global', () =\u003e { window.location.reload() })\n```\n\n### Examples with arguments\n\n```ts\nvim.addAlias(\n    'cc-vim',\n    'player-move',\n    'Move player',\n    'ingame',\n    (x?: string, y?: string, z?: string) =\u003e {\n        const pos: Vec3 = ig.game.playerEntity.coll.pos\n        ig.game.playerEntity.setPos(\n            pos.x + parseInt(x ?? '0'),\n            pos.y + parseInt(y ?? '0'), pos.z + parseInt(z ?? '0')\n        )\n    },\n    [\n        { type: 'number', description: 'x to add' },\n        { type: 'number', description: 'y to add' },\n        { type: 'number', description: 'z to add' },\n    ]\n)\n```\n\n```ts\nvim.addAlias(\n    'cc-vim',\n    'load-preset',\n    'Load save preset',\n    'global',\n    (presetId: string) =\u003e {\n        const id = parseInt(presetId.trim())\n        console.log('presetId:', id)\n    },\n    [{\n        type: 'number',\n        possibleArguments(): AliasArguemntEntry[] {\n            const arr: AliasArguemntEntry[] = []\n            for (const i of Object.keys(sc.savePreset.slots)) {\n                const slot: sc.SavePresetData = sc.savePreset.slots[parseInt(i)]\n                const value = i.toString()\n                const keys = [value, slot.title.value, slot.sub.value, slot.path]\n                arr.push({ value, keys, display: keys })\n            }\n            return arr\n        },\n        description: 'Preset to load',\n    }]\n)\n```\n\n## TypeScript support\n\n```bash\nnpm install --save-dev github:krypciak/cc-vim\n```\n\n```ts\nimport type * as _ from 'cc-vim'\n```\n\n## JavaScript support\n\nyou dummy learn typescript  \nthe same as typescript just remove the types (thingis behind `:`)\n\n## Contribution\n\nFeel free to pr any aliases you would like to see added\n\n## Building\n\n```bash\ngit clone https://github.com/krypciak/cc-vim\ncd cc-vim\npnpm install\npnpm run start\n# this should return no errors or very few\nnpx tsc\n```\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkrypciak%2Fcc-vim","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkrypciak%2Fcc-vim","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkrypciak%2Fcc-vim/lists"}