- Introduction
- Features
- Prerequisites
- Installation and Setup
- Using Commento
- Example Usage
- Keyboard Shortcuts
- Configuration
- Known Issues
- Release Notes
- Change Log
- Open Source Contribution
- License
Commento is a VS Code extension that generates concise and detailed comments for your code using Google Gemini AI. This documentation will guide you through the setup and usage of the extension.
- AI-powered comment generation using Google Gemini AI.
- Supports both concise and detailed comment styles.
- Easy integration with VS Code through command palette shortcuts.
- Option to include usage examples in detailed comments.
- Works with multiple programming languages.
- Open-source.
- A valid Google Gemini API key
- VS Code installed on your system
- Obtain API Key: Get your API key from Google Gemini at Google AI Studio.
- Configure API Key in VS Code:
- Open VS Code.
- Click on the gear icon ⚙ in the lower left corner, then go to Settings (
Ctrl + ,
on Windows/Linux,Cmd + ,
on Mac). - In the search bar at the top, type
Commento
. - Click on Commento in the Extensions section.
- Paste your API key into the provided field.
- Enable the checkbox "Include usage examples in detailed comments" if you want generated comments to include examples.
-
Select the function, class, or block of code where you want to generate comments.
-
Press
Ctrl + Shift + P
to open the command palette. -
Type
> Commento:
and select one of the following commands:- Commento: Concise Comment – Generates a short, one-line comment explaining the purpose of the selected code.
- Commento: Detailed Comment – Generates a more comprehensive, multi-line comment describing the functionality, parameters, and possible outcomes of the code.
Ctrl + Shift + P
→ Open Command PaletteCtrl + ,
(Windows/Linux) /Cmd + ,
(Mac) → Open Settings
You can configure Commento settings in VS Code:
commento.apiKey
: Your Google Gemini API key.commento.includeExamples
: Enable/Disable usage examples in detailed comments.
- Missing API Key: If you forget to add your Google Gemini API key, the extension will not function correctly. Make sure to follow the setup steps and verify that your API key is correctly entered in the settings.
Beta Version: Commento is currently in beta, and we are actively working on improvements. Feedback and bug reports are welcome!
- Improved user experience with a more intuitive interface.
- Enhanced comment generation for better clarity and accuracy.
- Added an option in settings to Include usage examples in detailed comments.
- Minor bug fixes and performance optimizations.
- v1.1.3: Improved UI, better comments, added example checkbox.
- v1.1.1: Fixed API key validation issue.
- v1.1.0: Initial public beta release.
This project is open-source! If you would like to contribute, check out the following links:
- GitHub Repository: Commento on GitHub
- VS Code Marketplace: Commento Extension
This project is licensed under the MIT License. See the LICENSE file for details.
Commento helps streamline code documentation by generating meaningful comments quickly. Use concise
for short explanations and detailed
for in-depth documentation.
🚀 Made with Rocket Coding