Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 22 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,11 @@ Night Shift scans your repositories overnight, finds lint errors, TypeScript iss

[![CI](https://github.com/FvdHMBAI/nightshift/actions/workflows/ci.yml/badge.svg)](https://github.com/FvdHMBAI/nightshift/actions/workflows/ci.yml)
[![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](LICENSE)
[![GitHub Stars](https://img.shields.io/github/stars/FvdHMBAI/nightshift?style=social)](https://github.com/FvdHMBAI/nightshift/stargazers)

<p align="center">
<img src="demo/demo.gif" alt="Night Shift Demo" width="700">
</p>

```
Night Shift Architecture
Expand Down Expand Up @@ -233,6 +238,23 @@ With Ollama: $0. With Claude API: typically $0.02-0.10 per run depending on find
**Can I run it manually?**
Yes: `./coordinator.sh` runs a full cycle. `./summary-morning.sh` generates/sends the summary.

## How It Compares

| | Night Shift | Renovate / Dependabot | CodeRabbit | Devin | Sweep (dead) |
|---|---|---|---|---|---|
| **Scope** | Lint + types + security + docs + deps | Dependencies only | Review only (no fixes) | Everything (interactive) | Issue-to-PR |
| **Runs when** | Overnight (cron) | On dependency update | On PR creation | On demand | On issue creation |
| **LLM choice** | Ollama (free) or Claude | None (rule-based) | Proprietary | Proprietary | Proprietary |
| **Self-hosted** | Yes | Partial (GitHub app) | No (SaaS) | No (cloud) | No |
| **Branch isolation** | Yes (one branch per fix) | Yes | N/A (no changes) | No (works in-place) | Yes |
| **Auto-rollback** | Yes (tsc fails = revert) | No | N/A | No | No |
| **Cost** | $0 (Ollama) / ~$0.05/run (Claude) | Free tier | $15/mo+ | $500/mo | Shut down |
| **Data stays local** | Yes | Partial | No | No | No |
| **Verification** | TypeScript + build check | CI pipeline | None | Manual review | CI pipeline |
| **Lesson generation** | Yes (Pro: explains WHY) | No | No | No | No |

**Different category.** Renovate and Dependabot handle one slice (dependency updates). CodeRabbit reviews but never fixes. Devin is a full interactive agent ($500/mo). Night Shift covers the boring maintenance layer between those tools: lint, types, security, docs. It runs unattended, on your hardware, with your LLM, and every fix is isolated on its own branch.

## Part of AgentStack

This tool is free and always will be. For teams that need the full governance stack (GuardRail Pro + Compliance Shield + priority support), see [AgentStack Pro](https://github.com/FvdHMBAI/agent-stack/blob/main/BUNDLE.md) (EUR 79/dev/month).
Expand Down
50 changes: 50 additions & 0 deletions demo/demo.cast
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
{"version": 2, "width": 80, "height": 24, "timestamp": 1786187569, "env": {"SHELL": "/bin/bash", "TERM": "xterm-256color"}}
[0.010799, "o", "\u001b[H\u001b[2J\u001b[3J"]
[0.012017, "o", "\r\n \u001b[1mNight Shift\u001b[0m \u001b[2mv1.0\u001b[0m\r\n \u001b[2mYour codebase improves while you sleep\u001b[0m\r\n\r\n"]
[1.013941, "o", "\u001b[2m$ \u001b[0mn"]
[1.047044, "o", "i"]
[1.079771, "o", "g"]
[1.112743, "o", "h"]
[1.145767, "o", "t"]
[1.178664, "o", "s"]
[1.211921, "o", "h"]
[1.24507, "o", "i"]
[1.278528, "o", "f"]
[1.311363, "o", "t"]
[1.344067, "o", " "]
[1.377068, "o", "r"]
[1.409918, "o", "u"]
[1.442687, "o", "n"]
[1.475843, "o", " "]
[1.508779, "o", "-"]
[1.541747, "o", "-"]
[1.574293, "o", "r"]
[1.60721, "o", "e"]
[1.639968, "o", "p"]
[1.672032, "o", "o"]
[1.704715, "o", "s"]
[1.736872, "o", " "]
[1.769866, "o", "~"]
[1.801783, "o", "/"]
[1.834897, "o", "p"]
[1.867961, "o", "r"]
[1.901105, "o", "o"]
[1.934456, "o", "j"]
[1.967538, "o", "e"]
[2.000765, "o", "c"]
[2.033557, "o", "t"]
[2.065262, "o", "s"]
[2.097883, "o", "/"]
[2.129588, "o", "*"]
[2.161181, "o", "\r\n"]
[2.664011, "o", "\r\n \u001b[0;36m02:00\u001b[0m Starting nightly scan across \u001b[1m4 repositories\u001b[0m\r\n\r\n"]
[3.167166, "o", " \u001b[1mScanning:\u001b[0m golf-club-community\r\n"]
[3.470081, "o", " \u001b[0;33m!\u001b[0m 3 ESLint errors \u001b[2m(unused imports)\u001b[0m\r\n \u001b[0;33m!\u001b[0m 1 TypeScript strict violation\r\n \u001b[0;32m+\u001b[0m Auto-fixed, committed to \u001b[2mfix/nightshift-lint-0808\u001b[0m\r\n"]
[4.07257, "o", "\r\n \u001b[1mScanning:\u001b[0m auth-provider\r\n"]
[4.37414, "o", " \u001b[0;31m!\u001b[0m 1 security issue \u001b[2m(missing rate limiter on /api/token)\u001b[0m\r\n \u001b[0;32m+\u001b[0m Patch created on \u001b[2mfix/nightshift-security-0808\u001b[0m\r\n"]
[4.976928, "o", "\r\n \u001b[1mScanning:\u001b[0m sales-hub\r\n"]
[5.278538, "o", " \u001b[0;32mOK\u001b[0m No issues found\r\n"]
[5.680066, "o", "\r\n \u001b[1mScanning:\u001b[0m golfschul-app\r\n"]
[5.98308, "o", " \u001b[0;33m!\u001b[0m 2 documentation gaps \u001b[2m(missing JSDoc on public API)\u001b[0m\r\n \u001b[0;32m+\u001b[0m Docs added, committed to \u001b[2mfix/nightshift-docs-0808\u001b[0m\r\n"]
[6.586008, "o", "\r\n \u001b[0;36m02:14\u001b[0m \u001b[1mNightly complete\u001b[0m\r\n\r\n"]
[6.586071, "o", " \u001b[1m4\u001b[0m repos scanned | \u001b[0;33m7\u001b[0m issues found | \u001b[0;32m6\u001b[0m auto-fixed | \u001b[0;31m1\u001b[0m needs review\r\n\r\n \u001b[2mMorning summary sent.\u001b[0m\r\n\r\n"]
Binary file added demo/demo.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
60 changes: 60 additions & 0 deletions demo/record-demo.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
#!/bin/bash
set -e
G=$'\033[0;32m' R=$'\033[0;31m' Y=$'\033[0;33m' B=$'\033[1m' D=$'\033[2m' Z=$'\033[0m' C=$'\033[0;36m'

type_cmd() {
printf "${D}\$ ${Z}"
for ((i=0; i<${#1}; i++)); do printf "%s" "${1:$i:1}"; sleep 0.03; done
echo ""
}

clear
echo ""
echo " ${B}Night Shift${Z} ${D}v1.0${Z}"
echo " ${D}Your codebase improves while you sleep${Z}"
echo ""
sleep 1

type_cmd "nightshift run --repos ~/projects/*"
sleep 0.5

echo ""
echo " ${C}02:00${Z} Starting nightly scan across ${B}4 repositories${Z}"
echo ""
sleep 0.5

echo " ${B}Scanning:${Z} golf-club-community"
sleep 0.3
echo " ${Y}!${Z} 3 ESLint errors ${D}(unused imports)${Z}"
echo " ${Y}!${Z} 1 TypeScript strict violation"
echo " ${G}+${Z} Auto-fixed, committed to ${D}fix/nightshift-lint-0808${Z}"
sleep 0.6

echo ""
echo " ${B}Scanning:${Z} auth-provider"
sleep 0.3
echo " ${R}!${Z} 1 security issue ${D}(missing rate limiter on /api/token)${Z}"
echo " ${G}+${Z} Patch created on ${D}fix/nightshift-security-0808${Z}"
sleep 0.6

echo ""
echo " ${B}Scanning:${Z} sales-hub"
sleep 0.3
echo " ${G}OK${Z} No issues found"
sleep 0.4

echo ""
echo " ${B}Scanning:${Z} golfschul-app"
sleep 0.3
echo " ${Y}!${Z} 2 documentation gaps ${D}(missing JSDoc on public API)${Z}"
echo " ${G}+${Z} Docs added, committed to ${D}fix/nightshift-docs-0808${Z}"
sleep 0.6

echo ""
echo " ${C}02:14${Z} ${B}Nightly complete${Z}"
echo ""
echo " ${B}4${Z} repos scanned | ${Y}7${Z} issues found | ${G}6${Z} auto-fixed | ${R}1${Z} needs review"
echo ""
echo " ${D}Morning summary sent.${Z}"
echo ""
sleep 3
Loading