Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

HyperGit Quick Switcher

HyperGit image

Cmd+K to search and open your GitHub repositories from any page. Caches repos locally for instant results.

Features

  • Login via Personal Access Token (PAT)
  • Fetches and caches all your repositories (respects private if token has scope)
  • Cmd+K / Ctrl+K to toggle palette
  • Type to filter, arrow up/down to navigate, Enter to open
  • Remembers recent repositories and surfaces them first

Why PAT and not OAuth?

Chrome extensions cannot safely store a GitHub OAuth client secret, and GitHub OAuth flows require the secret for token exchange. To avoid needing a backend server, this extension uses a user-provided PAT stored locally via chrome.storage.local.

You can switch to a backend + OAuth later by replacing the token handling in background.js.

Create a GitHub PAT

  1. Go to GitHub Settings → Developer settings → Personal access tokens → Fine-grained tokens
  2. Create a token with at least:
    • For public repos only: no extra scopes required beyond default repo read
    • For private repos: grant repository access (read) to the desired resources
  3. Copy the token (ghp_...).

Install in Chrome

  1. Open chrome://extensions
  2. Enable "Developer mode"
  3. Click "Load unpacked" and select this folder

Usage

  • On any page, press Cmd+K (macOS) or Ctrl+K (Windows/Linux) to toggle the palette
  • If prompted, paste your GitHub PAT and click "Save Token"
  • The extension will fetch and cache your repos (may take a moment for large accounts)
  • Start typing to filter; use arrow keys to navigate; press Enter to open the selected repo

Development Notes

  • Manifest V3 service worker: background.js
  • Content UI: contentScript.js + contentStyles.css
  • Storage keys and cache TTL are defined at the top of background.js
  • Recent repos are tracked by full_name and prioritized in results

Permissions

  • storage for token and repo cache
  • tabs, activeTab, scripting to inject the palette and open tabs
  • Host permissions for api.github.com and github.com to fetch/open

Switching to OAuth Later

If you add a small backend, you can implement the GitHub Web Application Flow safely:

  • Use chrome.identity.launchWebAuthFlow for user login
  • Exchange the authorization code for a token on your backend (keeps client secret server-side)
  • Store/access the token via the extension as in the PAT flow

Troubleshooting

  • If Cmd+K is taken by a site, change the shortcut in chrome://extensions → Keyboard shortcuts
  • Clear token: toggle the palette, then remove and re-add the extension or implement a small UI to call clearToken
  • Large orgs may need additional read scopes to list private repos

About

A chrome extension for quickly searching and accessing your git repos

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages