GitBolt is a Chrome extension that allows you to commit code directly from Compiler Explorer (Godbolt.org) to your GitHub repositories. It captures your code, generates a short link, and pushes it to a repository of your choice with a single click.
- Seamless Integration: Works directly within the Godbolt.org interface.
- GitHub Authentication: Securely authenticate using a Personal Access Token (PAT) with a user-friendly welcome flow.
- Repository Selection: Choose any of your GitHub repositories to save your code.
- Smart Commits:
- Auto-generates filenames with timestamps or lets you specify a custom name.
- Updates existing files if the filename matches.
- Includes a Godbolt short link in the commit for easy reference.
- Privacy Focused: Your token is stored locally in your browser and never sent to any third-party server.
(Coming Soon)
- Clone this repository:
git clone https://github.com/yourusername/gitbolt.git
- Open Chrome and navigate to
chrome://extensions. - Enable Developer mode in the top right corner.
- Click Load unpacked.
- Select the
gitboltdirectory from the cloned repository.
- Authenticate: Click the extension icon. If it's your first time, follow the "Welcome" flow to generate and save your GitHub Personal Access Token.
- Write Code: Go to godbolt.org and write your C++, Rust, Go, or Python code.
- Commit:
- Click the GitBolt icon.
- Select a target Repository.
- (Optional) Enter a Filename (e.g.,
solution.cpp). - Enter a Commit Message.
- Click Submit.
- Done!: Your code is now on GitHub with a link back to the Compiler Explorer session.
To create a zip file for distribution:
./build.shmanifest.json: Extension configuration (Manifest V3).popup.html/popup.js: The main extension interface.content.js: Script that runs on Godbolt.org to extract code and links.background.js: Service worker for handling installation events.welcome.html/welcome.js: Onboarding flow.
Contributions are welcome! Please open an issue or submit a pull request.


