{"id":13477188,"url":"https://github.com/raghur/vim-ghost","last_synced_at":"2025-08-28T09:09:11.022Z","repository":{"id":40685855,"uuid":"110437032","full_name":"raghur/vim-ghost","owner":"raghur","description":"Vim/Nvim client for GhostText - Edit browser text areas in Vim/Neovim","archived":false,"fork":false,"pushed_at":"2022-02-10T13:08:23.000Z","size":69,"stargazers_count":339,"open_issues_count":12,"forks_count":13,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-05-19T12:11:22.989Z","etag":null,"topics":["neovim","neovim-plugin","vim","vim-plugin"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/raghur.png","metadata":{"files":{"readme":"README.adoc","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-11-12T13:58:49.000Z","updated_at":"2025-04-19T02:49:28.000Z","dependencies_parsed_at":"2022-08-31T00:22:11.484Z","dependency_job_id":null,"html_url":"https://github.com/raghur/vim-ghost","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/raghur/vim-ghost","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/raghur%2Fvim-ghost","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/raghur%2Fvim-ghost/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/raghur%2Fvim-ghost/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/raghur%2Fvim-ghost/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/raghur","download_url":"https://codeload.github.com/raghur/vim-ghost/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/raghur%2Fvim-ghost/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":272475149,"owners_count":24940689,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-28T02:00:10.768Z","response_time":74,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"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":["neovim","neovim-plugin","vim","vim-plugin"],"created_at":"2024-07-31T16:01:39.241Z","updated_at":"2025-08-28T09:09:10.969Z","avatar_url":"https://github.com/raghur.png","language":"Python","funding_links":[],"categories":["Python"],"sub_categories":[],"readme":"= Vim Ghost\n\nEdit browser textarea content in Vim/Neovim!\n\n[.center.text-center]\nimage::https://i.imgur.com/yitnBrU.gif[demo,100%]\n\n. Install this https://addons.mozilla.org/en-US/firefox/addon/ghosttext/[firefox addon] or this https://chrome.google.com/webstore/detail/ghosttext/godiecgffnchndlihlpaajjcplehddca[Chrome extension]\n. Add this plugin\n+\n```\n\" Vim-plug\nPlug 'raghur/vim-ghost', {'do': ':GhostInstall'}\n```\n. Ensure you have a vim/neovim instance open. Run `:GhostStart` to start the server.\n. On any textarea, click the ghost icon - switch to neovim and edit!. Content is sync'ed real time. Works both ways - edits in the browser window are pushed to neovim as well.\n. When done, just delete the buffer with `:bd!` - you'll be disconnected\n\n== Configuring filetype\nWhenever a buffer is connected, a `User` event `vim-ghost#connected` is raised. Here's a quick sample of \nsetting filetype to `markdown` if the textarea was on github or reddit\n\n```\nfunction! s:SetupGhostBuffer()\n    if match(expand(\"%:a\"), '\\v/ghost-(github|reddit)\\.com-')\n        set ft=markdown\n    endif\nendfunction\n\naugroup vim-ghost\n    au!\n    au User vim-ghost#connected call s:SetupGhostBuffer()\naugroup END\n```\n\n== Requirements\n\n* Recent neovim/vim\n* Python 3.4+\n* Python plugin host - `python3 -c 'import pynvim'` should not error\n* Python websocket server https://github.com/dpallot/simple-websocket-server.git\n** This is automatically installed as a `pip --user` dependency when `:GhostInstall` runs.\n\n=== additional requirements for vim\n\n* https://github.com/roxma/vim-hug-neovim-rpc[vim-hug-neovim-rpc]\n* https://github.com/roxma/nvim-yarp[nvim-yarp]\n\n[source,vimscript]\n----\n\" Only enabled for Vim 8 (not for Neovim).\nPlug 'roxma/nvim-yarp', v:version \u003e= 800 \u0026\u0026 !has('nvim') ? {} : { 'on': [], 'for': [] }\nPlug 'roxma/vim-hug-neovim-rpc', v:version \u003e= 800 \u0026\u0026 !has('nvim') ? {} : { 'on': [], 'for': [] }\n----\n\n== Auto switching to vim:\n\n._Optional, but highly recommended - Switching focus to Neovim_\n* Linux: The `xdotool` command - if available, will be used to focus the nvim window.\nWorks in console, tmux or guis like neovim-qt\n** On Ubuntu, you can install it with `sudo apt-get install xdotool`\n* macOS: Set the `g:ghost_darwin_app` variable to the name of your app (see docs).\n* Windows: If pywinauto (https://github.com/pywinauto/pywinauto)\nis available, it will be used to bring the neovim-qt to foreground.\n+\n[source,shell]\n----\n# Ensure that you install this module for the version of python\n# that is loaded in neovim\npip install pywinauto\n----\nLimitations: Currently, on windows, the processname is hardcoded to nvim-qt\nIf you use any of the other GUIs for neovim (OniVim, gonvim etc) then this\nwill not work.\n\n== Rationale\n\nWith Firefox moving to webextensions, *It's all text* is dead. Typing in text areas is a royal PITA and I was looking for a replacement. Came across GhostText - but the vim addon seems dead and uses tcl :ugh:\n\nMy vimscript fu is pretty limited - so I thought I'd write a python plugin for neovim.\n\n== TODOS\n\nPR's welcome. Some areas:\n\n- [.line-through]#vim compatibility# - DONE\n\nLove it or just find it as useful as I do? Star this repo to let me know\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fraghur%2Fvim-ghost","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fraghur%2Fvim-ghost","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fraghur%2Fvim-ghost/lists"}