Package Exports
- gh2ide
- gh2ide/index.js
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (gh2ide) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
GitHub to IDE - Native Host
Native messaging host for the GitHub to IDE Chrome extension.
What is this?
This is a helper application that allows the GitHub to IDE browser extension to communicate with your computer to open repositories and files in your local IDE (VS Code, Cursor, JetBrains Rider, etc.).
Quick Install
npx gh2ide --extension-id <your-extension-id>
Finding Your Extension ID
- Open
chrome://extensions
in your browser - Enable "Developer mode" (toggle in top-right corner)
- Find the "GitHub to IDE" extension
- Copy the ID shown below the extension name (32 characters, looks like:
haekngngecedekgjbeoijeaapjkmblgp
)
Usage
Interactive Mode (Recommended)
Simply run without arguments and the CLI will auto-detect your extension:
npx gh2ide
Features:
- 🔍 Auto-detection: Scans your browser profiles for GitHub to IDE extension
- 🎯 Smart prompts: Confirms detected extension or lets you choose from multiple
- 📝 Manual fallback: If auto-detection fails, guides you through manual entry
The CLI will automatically find your extension in Chrome, Arc, Brave, Edge, or Chromium.
Note: Auto-detection only works for installed extensions (from Chrome Web Store or packed .crx files). Unpacked extensions loaded via "Load unpacked" must be entered manually.
Direct Installation
If you already know your extension ID:
npx gh2ide --extension-id abc123xyz
Help
npx gh2ide --help
Version
npx gh2ide --version
Uninstall
npx gh2ide --uninstall
This removes all installed files and manifests from all browsers.
What it Does
- Installs the native messaging host to
~/.github-to-ide/native-host/
- Creates a manifest file that allows Chrome to communicate with the host
- Configures your browser(s) to recognize the extension
Supported Platforms
- ✅ macOS - Automatically installs for Chrome, Brave, Edge, Chromium
- ✅ Linux - Automatically installs for Chrome, Brave, Chromium
- ⚠️ Windows - Requires manual registry configuration (see Windows Setup)
Supported Browsers
- Chrome
- Chromium
- Brave
- Microsoft Edge
- Arc (uses Chrome profile)
- Vivaldi (uses Chrome profile)
After Installation
- Restart your browser - This is required for the browser to recognize the native host
- Test the connection - Open the extension options page and click "Test native host connection"
- Configure your IDE - Set your preferred editor and clone directory in the extension options
Windows Setup
Windows requires additional steps due to registry requirements:
- Run the installer:
npx gh2ide --extension-id <your-id>
- Open Registry Editor (
regedit
) - Navigate to:
HKEY_CURRENT_USER\Software\Google\Chrome\NativeMessagingHosts
- Create a new key:
com.lovelesslabs.vscodeopener
- Set the default value to the path shown by the installer
For more details, see the Chrome Native Messaging documentation.
Updating
To update to the latest version:
npx gh2ide@latest --extension-id <your-id>
Uninstalling
To completely remove the native host:
npx gh2ide --uninstall
This automatically removes:
- Installation directory (
~/.github-to-ide
) - All browser manifests (Chrome, Brave, Edge, Chromium)
- Configuration files
Manual uninstall (if needed):
If the automatic uninstall doesn't work, you can manually remove files:
macOS:
rm -rf ~/.github-to-ide
rm ~/Library/Application\ Support/Google/Chrome/NativeMessagingHosts/com.lovelesslabs.vscodeopener.json
rm ~/Library/Application\ Support/BraveSoftware/Brave-Browser/NativeMessagingHosts/com.lovelesslabs.vscodeopener.json
Linux:
rm -rf ~/.github-to-ide
rm ~/.config/google-chrome/NativeMessagingHosts/com.lovelesslabs.vscodeopener.json
rm ~/.config/BraveSoftware/Brave-Browser/NativeMessagingHosts/com.lovelesslabs.vscodeopener.json
Troubleshooting
"No response from native host"
- Ensure you've restarted your browser after installation
- Check that the extension ID matches what you installed with
- Run the installer again:
npx gh2ide --extension-id <your-id>
"Native host has exited"
- Ensure Node.js is installed:
node --version
(requires v16+) - Check the native host log:
~/.github-vscode-interceptor/native-host.log
Extension ID doesn't match
If you reinstall the extension or switch browsers, you may need to reinstall the native host with the new extension ID.
Requirements
- Node.js 16 or higher
- Chrome/Chromium-based browser
- macOS, Linux, or Windows
Development
To test locally:
git clone https://github.com/justinloveless/github-to-ide.git
cd github-to-ide/native-host
npm link
gh2ide --extension-id <your-id>
License
MIT
Issues & Support
Report issues at: https://github.com/justinloveless/github-to-ide/issues