Gemini CLI skill enables Claude to use Gemini 3 Pro via CLI for code generation and review. Developers benefit from automated code creation and quality checks. Integrates with existing development workflows and IDEs.
git clone https://github.com/forayconsulting/gemini_cli_skill.gitGemini CLI skill enables Claude to use Gemini 3 Pro via CLI for code generation and review. Developers benefit from automated code creation and quality checks. Integrates with existing development workflows and IDEs.
1. **Installation**: Ensure gemini_cli_skill is installed and configured in your development environment. Verify with `gemini_cli_skill --version`. 2. **Project Setup**: Navigate to your project root directory where the code will be generated. 3. **Prompt Customization**: Replace [PROJECT_NAME], [LANGUAGE], [FUNCTIONALITY_DESCRIPTION], and [FILE_PATH] in the prompt template with your specific requirements. 4. **Execution**: Run the command either directly in your terminal or through your IDE's terminal integration. For complex projects, break functionality into smaller components. 5. **Review Integration**: After generation, use the review output to iterate on the code. Focus on security flags and performance notes first. **Tips for Better Results:** - Include specific requirements like framework versions (e.g., 'using FastAPI 0.109.0') - Specify performance constraints (e.g., 'must handle 1000 requests/second') - For reviews, include your existing codebase context (e.g., 'this will integrate with our existing PostgreSQL schema') - Use the --verbose flag to get detailed reasoning behind suggestions
No install command available. Check the GitHub repository for manual installation instructions.
git clone https://github.com/forayconsulting/gemini_cli_skillCopy the install command above and run it in your terminal.
Launch Claude Code, Cursor, or your preferred AI coding agent.
Use the prompt template or examples below to test the skill.
Adapt the skill to your specific use case and workflow.
Use the gemini_cli_skill to generate and review code for [PROJECT_NAME]. Generate a [LANGUAGE] implementation for [FUNCTIONALITY_DESCRIPTION]. After generation, run a comprehensive review to identify potential bugs, performance bottlenecks, and security vulnerabilities. Provide the final code with inline comments explaining key optimizations and trade-offs. Use the following command structure: `gemini_cli_skill --generate --review --language [LANGUAGE] --output [FILE_PATH]`
```python
# File: user_auth_service.py
# Generated by gemini_cli_skill for project 'SecureApp'
# Reviewed for security and performance issues on 2024-05-15
import bcrypt
import jwt
from datetime import datetime, timedelta
from typing import Optional
class UserAuthService:
def __init__(self, secret_key: str):
self.secret_key = secret_key
# Security Note: secret_key should be loaded from environment variables in production
def hash_password(self, password: str) -> str:
"""Securely hash a password using bcrypt with cost factor 12"""
salt = bcrypt.gensalt(rounds=12)
return bcrypt.hashpw(password.encode('utf-8'), salt).decode('utf-8')
def verify_password(self, password: str, hashed: str) -> bool:
"""Verify a password against its hashed version"""
return bcrypt.checkpw(password.encode('utf-8'), hashed.encode('utf-8'))
def generate_token(self, user_id: str, expires_in: int = 3600) -> str:
"""Generate a JWT token with expiration"""
payload = {
'sub': user_id,
'iat': datetime.utcnow(),
'exp': datetime.utcnow() + timedelta(seconds=expires_in)
}
return jwt.encode(payload, self.secret_key, algorithm='HS256')
def validate_token(self, token: str) -> Optional[str]:
"""Validate a JWT token and return user_id if valid"""
try:
payload = jwt.decode(token, self.secret_key, algorithms=['HS256'])
return payload['sub']
except jwt.ExpiredSignatureError:
raise ValueError("Token has expired")
except jwt.InvalidTokenError:
raise ValueError("Invalid token")
# Performance Note: Consider using async bcrypt for high-load scenarios
# Security Note: Implement token blacklisting for logout functionality
```
**Review Summary:**
1. **Security:** ✅ Uses bcrypt with appropriate cost factor (12) for password hashing. JWT implementation is secure with HS256 algorithm.
2. **Performance:** ⚠️ Synchronous bcrypt operations may cause blocking under high load. Consider async alternatives.
3. **Bugs:** ❌ No input validation for password strength (should enforce min length/complexity)
4. **Improvements:** Add token blacklisting mechanism for logout functionality. Consider rate limiting for auth endpoints.
**Recommendations:**
- Add password complexity requirements in hash_password()
- Implement async bcrypt for production use
- Add token revocation list for logout functionality
- Consider adding refresh token mechanismGoogle's multimodal AI model and assistant
AI assistant built for thoughtful, nuanced conversation
IronCalc is a spreadsheet engine and ecosystem
Customer feedback management made simple
Enterprise workflow automation and service management platform
Automate your spreadsheet tasks with AI power
Take a free 3-minute scan and get personalized AI skill recommendations.
Take free scan