change package name to devgen-cli for pypi compatiable
This commit is contained in:
9 files changed
+339
-5
No files matched your search
@@ -0,0 +1,286 @@
|
|||||||
|
Metadata-Version: 2.4
|
||||||
|
Name: devgen-cli
|
||||||
|
Version: 0.2.0
|
||||||
|
Summary: A collection of developer tools
|
||||||
|
Home-page: https://github.com/S4NKALP/devgen
|
||||||
|
Author: Sankalp Tharu
|
||||||
|
Author-email: Sankalp Tharu <sankalptharu50028@gmail.com>
|
||||||
|
License: GPL-3.0-or-later
|
||||||
|
Project-URL: Homepage, https://github.com/S4NKALP/devgen
|
||||||
|
Keywords: devgen,cli,git,changelog,gitignore,license,commit-generator,commit
|
||||||
|
Classifier: Development Status :: 3 - Alpha
|
||||||
|
Classifier: Intended Audience :: Developers
|
||||||
|
Classifier: License :: OSI Approved :: GNU General Public License v3 or later (GPLv3+)
|
||||||
|
Classifier: Operating System :: OS Independent
|
||||||
|
Classifier: Programming Language :: Python :: 3
|
||||||
|
Classifier: Programming Language :: Python :: 3.7
|
||||||
|
Classifier: Programming Language :: Python :: 3.8
|
||||||
|
Classifier: Programming Language :: Python :: 3.9
|
||||||
|
Classifier: Programming Language :: Python :: 3.10
|
||||||
|
Requires-Python: >=3.10
|
||||||
|
Description-Content-Type: text/markdown
|
||||||
|
License-File: LICENSE
|
||||||
|
Requires-Dist: anthropic>=0.75.0
|
||||||
|
Requires-Dist: google-generativeai>=0.8.5
|
||||||
|
Requires-Dist: jinja2>=3.1.6
|
||||||
|
Requires-Dist: openai>=2.11.0
|
||||||
|
Requires-Dist: pyyaml>=6.0.3
|
||||||
|
Requires-Dist: questionary>=2.1.1
|
||||||
|
Requires-Dist: requests>=2.32.5
|
||||||
|
Requires-Dist: rich>=14.2.0
|
||||||
|
Requires-Dist: toml>=0.10.2
|
||||||
|
Requires-Dist: typer>=0.20.0
|
||||||
|
Dynamic: author
|
||||||
|
Dynamic: home-page
|
||||||
|
Dynamic: license-file
|
||||||
|
Dynamic: requires-python
|
||||||
|
|
||||||
|
# DevGen
|
||||||
|
|
||||||
|
<div align="center">
|
||||||
|
|
||||||
|
<img src="https://img.shields.io/pypi/v/devgen?color=blue&label=PyPI&logo=pypi&logoColor=white" alt="PyPI">
|
||||||
|
<img src="https://img.shields.io/badge/Python-3.10%2B-3776AB?logo=python&logoColor=white" alt="Python">
|
||||||
|
<a href="https://github.com/S4NKALP/devgen/blob/main/LICENSE"><img src="https://img.shields.io/badge/License-GPL--3.0--or--later-blue.svg" alt="License"></a>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
**DevGen** is an AI-powered developer toolkit that automates common Git and project management tasks. Generate semantic commit messages, changelogs, release notes, `.gitignore` files, and licenses—all from a single unified CLI.
|
||||||
|
|
||||||
|
## ✨ Features
|
||||||
|
|
||||||
|
- 🚀 **AI-Powered Commit Messages** - Automatically generate semantic commit messages from your staged changes using AI
|
||||||
|
- 📝 **Changelog Generation** - Create changelogs from git history using conventional commits
|
||||||
|
- 🚀 **Release Notes** - Generate clean, emoji-enhanced release notes for your releases
|
||||||
|
- 🙈 **Gitignore Templates** - Generate `.gitignore` files from GitHub's official templates
|
||||||
|
- 📄 **License Generation** - Quickly generate open source licenses with interactive setup
|
||||||
|
- ⚙️ **Multi-Provider AI Support** - Works with Gemini, OpenAI, Anthropic, HuggingFace, and OpenRouter
|
||||||
|
|
||||||
|
## 📦 Installation
|
||||||
|
|
||||||
|
```bash
|
||||||
|
# Stable release from PyPI
|
||||||
|
pip install devgen
|
||||||
|
|
||||||
|
# Using pipx (recommended for isolated CLI)
|
||||||
|
pipx install devgen
|
||||||
|
|
||||||
|
# Using uv (fast Python package manager)
|
||||||
|
uv tool install devgen
|
||||||
|
```
|
||||||
|
|
||||||
|
## 🚀 Quick Start
|
||||||
|
|
||||||
|
### 1. Initial Setup
|
||||||
|
|
||||||
|
Configure your AI provider and API key:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
devgen setup config
|
||||||
|
```
|
||||||
|
|
||||||
|
This will create a configuration file at `~/.devgen.yaml` with your preferred AI provider, model, and API key.
|
||||||
|
|
||||||
|
### 2. Generate Commit Messages
|
||||||
|
|
||||||
|
Stage your changes and let DevGen generate semantic commit messages:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
# Dry run to preview commit messages
|
||||||
|
devgen commit run --dry-run
|
||||||
|
|
||||||
|
# Actually commit with AI-generated messages
|
||||||
|
devgen commit run
|
||||||
|
|
||||||
|
# Commit and automatically push
|
||||||
|
devgen commit run --push
|
||||||
|
|
||||||
|
# Force regeneration of commit messages
|
||||||
|
devgen commit run --force-rebuild
|
||||||
|
```
|
||||||
|
|
||||||
|
**How it works:**
|
||||||
|
- DevGen detects all staged and unstaged changes
|
||||||
|
- Groups files by directory
|
||||||
|
- Generates semantic commit messages for each group using AI
|
||||||
|
- Follows [Conventional Commits](https://www.conventionalcommits.org/) format
|
||||||
|
|
||||||
|
**Additional commit commands:**
|
||||||
|
```bash
|
||||||
|
# View cached commit messages
|
||||||
|
devgen commit list-cached
|
||||||
|
|
||||||
|
# Clear the commit cache
|
||||||
|
devgen commit clear-cache
|
||||||
|
|
||||||
|
# Check what files are staged
|
||||||
|
devgen commit validate
|
||||||
|
```
|
||||||
|
|
||||||
|
### 3. Generate Changelogs
|
||||||
|
|
||||||
|
Create changelogs from your git history:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
# Generate changelog from last tag to HEAD
|
||||||
|
devgen changelog generate
|
||||||
|
|
||||||
|
# Generate from a specific reference
|
||||||
|
devgen changelog generate --from v1.0.0
|
||||||
|
|
||||||
|
# Output to a custom file
|
||||||
|
devgen changelog generate --output CHANGES.md
|
||||||
|
```
|
||||||
|
|
||||||
|
The changelog follows Semantic Release conventions, categorizing commits into:
|
||||||
|
- **BREAKING CHANGES**
|
||||||
|
- **Features**
|
||||||
|
- **Bug Fixes**
|
||||||
|
- **Documentation**
|
||||||
|
- **Other Changes**
|
||||||
|
|
||||||
|
### 4. Generate Release Notes
|
||||||
|
|
||||||
|
Create release notes for your releases:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
# Generate release notes
|
||||||
|
devgen release notes --version 1.4.0
|
||||||
|
|
||||||
|
# Custom output file
|
||||||
|
devgen release notes --version 1.4.0 --output RELEASE.md
|
||||||
|
|
||||||
|
# From a specific reference
|
||||||
|
devgen release notes --version 1.4.0 --from v1.3.0
|
||||||
|
```
|
||||||
|
|
||||||
|
### 5. Generate .gitignore Files
|
||||||
|
|
||||||
|
Create `.gitignore` files from GitHub templates:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
# Interactive mode (search and select templates)
|
||||||
|
devgen gitignore generate
|
||||||
|
|
||||||
|
# Specify templates directly
|
||||||
|
devgen gitignore generate Python Node Docker
|
||||||
|
|
||||||
|
# List available templates
|
||||||
|
devgen gitignore list
|
||||||
|
|
||||||
|
# Use cached templates (offline mode)
|
||||||
|
devgen gitignore generate --offline Python
|
||||||
|
```
|
||||||
|
|
||||||
|
**Options:**
|
||||||
|
- `--append` / `--overwrite` - Append to or overwrite existing `.gitignore`
|
||||||
|
- `--output` - Specify output file path (default: `.gitignore`)
|
||||||
|
- `--offline` - Use only cached templates
|
||||||
|
|
||||||
|
### 6. Generate Licenses
|
||||||
|
|
||||||
|
Generate open source licenses interactively:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
devgen license generate
|
||||||
|
```
|
||||||
|
|
||||||
|
This will:
|
||||||
|
1. Show available licenses (MIT, Apache-2.0, GPL-3.0, etc.)
|
||||||
|
2. Prompt for author name
|
||||||
|
3. Prompt for year (defaults to current year)
|
||||||
|
4. Generate the license file
|
||||||
|
|
||||||
|
**Available licenses:**
|
||||||
|
- MIT
|
||||||
|
- Apache-2.0
|
||||||
|
- GPL-2.0, GPL-3.0
|
||||||
|
- LGPL-2.1
|
||||||
|
- AGPL-3.0
|
||||||
|
- BSD-2-Clause, BSD-3-Clause
|
||||||
|
- MPL-2.0
|
||||||
|
- EPL-2.0
|
||||||
|
- BSL-1.0
|
||||||
|
- CC0-1.0
|
||||||
|
- Unlicense
|
||||||
|
|
||||||
|
## ⚙️ Configuration
|
||||||
|
|
||||||
|
Configuration is stored in `~/.devgen.yaml`. You can edit it manually or use the interactive setup:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
devgen setup config
|
||||||
|
```
|
||||||
|
|
||||||
|
**Configuration options:**
|
||||||
|
- `provider` - AI provider: `gemini`, `openai`, `anthropic`, `huggingface`, or `openrouter`
|
||||||
|
- `model` - Model name (e.g., `gemini-2.5-flash`, `gpt-4`, `claude-3-opus`)
|
||||||
|
- `api_key` - Your API key
|
||||||
|
- `emoji` - Enable/disable emojis in commit messages (default: `true`)
|
||||||
|
|
||||||
|
## 📋 Command Reference
|
||||||
|
|
||||||
|
### Commit Commands
|
||||||
|
```bash
|
||||||
|
devgen commit run [--dry-run] [--push] [--debug] [--force-rebuild]
|
||||||
|
devgen commit validate
|
||||||
|
devgen commit list-cached
|
||||||
|
devgen commit clear-cache
|
||||||
|
```
|
||||||
|
|
||||||
|
### Changelog Commands
|
||||||
|
```bash
|
||||||
|
devgen changelog generate [--output FILE] [--from REF]
|
||||||
|
```
|
||||||
|
|
||||||
|
### Release Commands
|
||||||
|
```bash
|
||||||
|
devgen release notes [--version VERSION] [--output FILE] [--from REF]
|
||||||
|
```
|
||||||
|
|
||||||
|
### Gitignore Commands
|
||||||
|
```bash
|
||||||
|
devgen gitignore generate [TEMPLATES...] [--output FILE] [--append/--overwrite] [--offline]
|
||||||
|
devgen gitignore list [--cached]
|
||||||
|
```
|
||||||
|
|
||||||
|
### License Commands
|
||||||
|
```bash
|
||||||
|
devgen license generate [--output FILE]
|
||||||
|
```
|
||||||
|
|
||||||
|
### Setup Commands
|
||||||
|
```bash
|
||||||
|
devgen setup config
|
||||||
|
```
|
||||||
|
|
||||||
|
## 🎯 Use Cases
|
||||||
|
|
||||||
|
- **Automated Commit Workflow**: Let AI analyze your changes and generate meaningful commit messages
|
||||||
|
- **Release Preparation**: Automatically generate changelogs and release notes from git history
|
||||||
|
- **Project Setup**: Quickly add `.gitignore` and license files to new projects
|
||||||
|
- **CI/CD Integration**: Use in scripts to automate documentation generation
|
||||||
|
|
||||||
|
## 🔧 Requirements
|
||||||
|
|
||||||
|
- Python 3.10 or higher
|
||||||
|
- Git repository (for commit/changelog/release features)
|
||||||
|
- API key for your chosen AI provider
|
||||||
|
|
||||||
|
## 📝 License
|
||||||
|
|
||||||
|
This project is licensed under the GPL-3.0-or-later License - see the [LICENSE](LICENSE) file for details.
|
||||||
|
|
||||||
|
## 🤝 Contributing
|
||||||
|
|
||||||
|
Contributions are welcome! Please feel free to submit a Pull Request.
|
||||||
|
|
||||||
|
## 📚 Links
|
||||||
|
|
||||||
|
- **Homepage**: [https://github.com/S4NKALP/devgen](https://github.com/S4NKALP/devgen)
|
||||||
|
- **PyPI**: [https://pypi.org/project/devgen](https://pypi.org/project/devgen)
|
||||||
|
|
||||||
|
## 🙏 Acknowledgments
|
||||||
|
|
||||||
|
- Uses GitHub's official [gitignore templates](https://github.com/github/gitignore)
|
||||||
|
- Follows [Conventional Commits](https://www.conventionalcommits.org/) specification
|
||||||
@@ -0,0 +1,34 @@
|
|||||||
|
LICENSE
|
||||||
|
README.md
|
||||||
|
pyproject.toml
|
||||||
|
setup.py
|
||||||
|
devgen/__init__.py
|
||||||
|
devgen/ai.py
|
||||||
|
devgen/utils.py
|
||||||
|
devgen/cli/__init__.py
|
||||||
|
devgen/cli/changelog.py
|
||||||
|
devgen/cli/commit.py
|
||||||
|
devgen/cli/config.py
|
||||||
|
devgen/cli/gitignore.py
|
||||||
|
devgen/cli/license.py
|
||||||
|
devgen/cli/main.py
|
||||||
|
devgen/cli/release.py
|
||||||
|
devgen/cli/setup.py
|
||||||
|
devgen/modules/__init__.py
|
||||||
|
devgen/modules/changelog_generator.py
|
||||||
|
devgen/modules/commit_generator.py
|
||||||
|
devgen/modules/gitignore_generator.py
|
||||||
|
devgen/modules/license_generator.py
|
||||||
|
devgen/modules/release_note_generator.py
|
||||||
|
devgen/providers/__init__.py
|
||||||
|
devgen/providers/anthropic.py
|
||||||
|
devgen/providers/gemini.py
|
||||||
|
devgen/providers/huggingface.py
|
||||||
|
devgen/providers/openai.py
|
||||||
|
devgen/providers/openrouter.py
|
||||||
|
devgen_cli.egg-info/PKG-INFO
|
||||||
|
devgen_cli.egg-info/SOURCES.txt
|
||||||
|
devgen_cli.egg-info/dependency_links.txt
|
||||||
|
devgen_cli.egg-info/entry_points.txt
|
||||||
|
devgen_cli.egg-info/requires.txt
|
||||||
|
devgen_cli.egg-info/top_level.txt
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
|
||||||
@@ -0,0 +1,2 @@
|
|||||||
|
[console_scripts]
|
||||||
|
devgen = devgen.cli.main:app
|
||||||
@@ -0,0 +1,10 @@
|
|||||||
|
anthropic>=0.75.0
|
||||||
|
google-generativeai>=0.8.5
|
||||||
|
jinja2>=3.1.6
|
||||||
|
openai>=2.11.0
|
||||||
|
pyyaml>=6.0.3
|
||||||
|
questionary>=2.1.1
|
||||||
|
requests>=2.32.5
|
||||||
|
rich>=14.2.0
|
||||||
|
toml>=0.10.2
|
||||||
|
typer>=0.20.0
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
devgen
|
||||||
+1
-1
@@ -3,7 +3,7 @@ requires = ["setuptools>=61", "wheel"]
|
|||||||
build-backend = "setuptools.build_meta"
|
build-backend = "setuptools.build_meta"
|
||||||
|
|
||||||
[project]
|
[project]
|
||||||
name = "devgen"
|
name = "devgen-cli"
|
||||||
version = "0.2.0"
|
version = "0.2.0"
|
||||||
description = "A collection of developer tools"
|
description = "A collection of developer tools"
|
||||||
readme = "README.md"
|
readme = "README.md"
|
||||||
|
|||||||
@@ -5,7 +5,7 @@ Setup script for devgen package.
|
|||||||
from setuptools import find_packages, setup
|
from setuptools import find_packages, setup
|
||||||
|
|
||||||
setup(
|
setup(
|
||||||
name="devgen",
|
name="devgen-setup",
|
||||||
version="0.2.0",
|
version="0.2.0",
|
||||||
packages=find_packages(),
|
packages=find_packages(),
|
||||||
include_package_data=True,
|
include_package_data=True,
|
||||||
|
|||||||
@@ -188,8 +188,8 @@ wheels = [
|
|||||||
]
|
]
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "devgen"
|
name = "devgen-cli"
|
||||||
version = "0.1.0"
|
version = "0.2.0"
|
||||||
source = { editable = "." }
|
source = { editable = "." }
|
||||||
dependencies = [
|
dependencies = [
|
||||||
{ name = "anthropic" },
|
{ name = "anthropic" },
|
||||||
@@ -262,7 +262,7 @@ name = "exceptiongroup"
|
|||||||
version = "1.3.1"
|
version = "1.3.1"
|
||||||
source = { registry = "https://pypi.org/simple" }
|
source = { registry = "https://pypi.org/simple" }
|
||||||
dependencies = [
|
dependencies = [
|
||||||
{ name = "typing-extensions", marker = "python_full_version < '3.13'" },
|
{ name = "typing-extensions", marker = "python_full_version < '3.11'" },
|
||||||
]
|
]
|
||||||
sdist = { url = "https://files.pythonhosted.org/packages/50/79/66800aadf48771f6b62f7eb014e352e5d06856655206165d775e675a02c9/exceptiongroup-1.3.1.tar.gz", hash = "sha256:8b412432c6055b0b7d14c310000ae93352ed6754f70fa8f7c34141f91c4e3219", size = 30371, upload-time = "2025-11-21T23:01:54.787Z" }
|
sdist = { url = "https://files.pythonhosted.org/packages/50/79/66800aadf48771f6b62f7eb014e352e5d06856655206165d775e675a02c9/exceptiongroup-1.3.1.tar.gz", hash = "sha256:8b412432c6055b0b7d14c310000ae93352ed6754f70fa8f7c34141f91c4e3219", size = 30371, upload-time = "2025-11-21T23:01:54.787Z" }
|
||||||
wheels = [
|
wheels = [
|
||||||
|
|||||||
Reference in new issue
Block a user