Package Exports
- @anthuanvasquez/devlogs
- @anthuanvasquez/devlogs/index.js
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (@anthuanvasquez/devlogs) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
devlogs π
Automated daily commit reports powered by Gemini AI, delivered to Discord and Telegram.
Features
- π Scans commits from the current day.
- π€ Generates a concise summary using Google Gemini AI.
- π Sends reports to Discord Webhooks and/or Telegram Bots.
- interactive CLI prompt to choose destination if both are configured.
- π¦ Supports multiple projects via a script.
Prerequisites
- Node.js (v18 or higher recommended)
- Git installed and available in PATH.
- A Google Gemini API Key (Get it here).
- A Discord Webhook URL (optional).
- A Telegram Bot Token and Chat ID (optional).
Installation
From NPM (Recommended)
npx devlogsFrom Source
Clone the repository:
git clone https://github.com/anthuanvasquez/devlogs.git cd devlogs
Install dependencies:
npm install
Link the package globally:
npm link
Configuration
Create a .env file in the root of your project or where you intend to run the script (or set them as system environment variables):
# Required
GEMINI_API_KEY=your_gemini_api_key
# Optional (at least one is required)
DISCORD_WEBHOOK_URL=your_discord_webhook_url
TELEGRAM_BOT_TOKEN=your_telegram_bot_token
TELEGRAM_CHAT_ID=your_telegram_chat_idUsage
Navigate to any git repository and run:
devlogs [today|yesterday] [--discord] [--telegram]
# Default (today, ask if multiple targets)
devlogs
# Report for yesterday
devlogs yesterday
# Force send to Discord (skip prompt)
devlogs today --discord
# Force send to Telegram (skip prompt)
devlogs yesterday --telegram
# Send to both without prompt
devlogs --discord --telegramIf multiple destinations are configured, you will be prompted to choose:
ΒΏDΓ³nde deseas enviar el reporte? (discord/telegram/ambos) [ambos]:
Running for Multiple Projects
You can create a projects.json file with an array of absolute paths to your projects:
[
"/path/to/project-a",
"/path/to/project-b"
]Then run the included script:
./run-all-projects.shAutomating with Cron
To run it automatically every day at 6:00 PM:
Open your crontab:
crontab -e
Add the following line (adjust paths accordingly):
0 18 * * 1-5 /path/to/dev-logs/run-all-projects.sh >> /tmp/cron_devlogs.txt 2>&1
License
MIT