ข้ามไปเนื้อหาหลัก

● กำลังพัฒนา

Daily Summary Bot

LINE Notify bot สรุปงานประจำวัน — ดึง git commits, tasks จาก todo file และ send สรุปผ่าน LINE ทุกเย็น

· อ่านประมาณ 1 นาที

สารบัญ

ภาพรวม

สิ้นวันมักลืมว่าทำอะไรไปบ้าง — โดยเฉพาะวันที่ทำงานหลายอย่างสลับกัน bot นี้รัน cron job ทุก 18:00 น. ดึงข้อมูลจากหลายแหล่ง แล้วส่งสรุปมาที่ LINE

สิ่งที่ทำแล้ว

  • Git summarygit log --since="00:00" ใน repos ที่ config ไว้ สรุป commits วันนี้
  • Task parser — อ่าน todo.md file ตาม format - [x] done / - [ ] pending นับ completed vs pending
  • LINE Notify — ส่งผ่าน LINE Notify API (token เก็บใน env)
  • Cron scheduling — รันด้วย node-cron ไม่ต้องพึ่ง systemd cron
  • Message format — Markdown-friendly ที่ LINE render ได้ มี emoji section headers
  • Manual triggernpm run summary รัน on-demand ได้ด้วย

ตัวอย่าง Message

📋 สรุปวัน 15 มิ.ย. 2026

💻 Git Commits (3)
• panupong-ws: feat: add /reading collection
• csv-budget-cli: fix: handle empty CSV rows
• daily-summary-bot: chore: add node-cron

✅ Tasks: 5/7 เสร็จ
• ✅ ตรวจ product catalog
• ✅ อัพเดต content SEO
• ⏳ เขียน notes 2 อัน
• ⏳ review PR

⏰ ส่งอัตโนมัติ เวลา 18:00 น.

กำลังทำ

  • Notion integration — ดึง tasks จาก Notion database
  • Weekly report — สรุปรายสัปดาห์ทุกวันศุกร์
  • Streak tracking — นับ streak วันที่ทำงาน consecutive

เทคโนโลยี

  • TypeScript + Node.js 22
  • node-cron สำหรับ scheduling
  • simple-git สำหรับ git log
  • LINE Notify REST API
  • .env สำหรับ token (ไม่ commit)