# Project pack: Donetick @ 1291130

Facts about **Donetick** for an AI following the [BespokeAI handover guide](https://handoff.bespokeai.software/guide/v2.md). This pack is pinned to one version and never changes after publication.

> Donetick is a task and chore manager for households and small teams. Chores can repeat on a schedule or rotate between people, be done together, and earn points that you can trade for rewards. It sends reminders and runs as one small Go service with a built-in database.

## Version and source
- Repository: https://github.com/donetick/donetick
- Pinned commit: `1291130d7d1940a506fb18ab19bc40c833eedab9`. Use exactly this version.
- Fresh checkout: use the setup below in an empty folder. If you already have this exact source checked out, keep your branch and use the development command instead; do not clone again or reset local changes.
- Or download a zip: https://github.com/donetick/donetick/archive/1291130d7d1940a506fb18ab19bc40c833eedab9.zip
- Official docs: https://docs.donetick.com
- Live demo: https://app.donetick.com/. The project's hosted app. Don't enter anything private.
- Licence: **AGPL-3.0-only**. Free to use and change. If other people use your changed version, including over a network (for example a website you host for them), you must offer them your source code under the same licence. Using it privately for yourself or your household has no extra obligations.

## Running the pinned source
- Fresh pinned-source setup (skip clone and checkout in an existing worktree):

  ```sh
  git clone https://github.com/donetick/donetick bespoke-donetick
  cd bespoke-donetick
  git checkout --detach 1291130d7d1940a506fb18ab19bc40c833eedab9
  # Prepare development requirements and local configuration first.
  cd frontend
  npm install
  npm run build
  cd ..
  go run .
  ```

The commands below are a starting point from the reviewed source. Prepare the listed tools, local configuration and companion services before starting the app. These instructions have not yet been validated in participant sessions.

### Separate trial of the current release
This tries an upstream release, which may differ from the pinned source above. It does not run your source changes. Use only sample data and a separate data directory or volume. Check the upstream documentation before running it.

  ```sh
  docker run -d --name donetick -p 2021:2021 -e DT_ENV=selfhosted -e DT_SQLITE_PATH=/donetick-data/donetick.db -e TZ=Etc/UTC -v donetick-data:/donetick-data -v donetick-config:/config donetick/donetick
  # then open http://localhost:2021
  ```

- Needs: Docker for a trial, Go and Node for development
- Develop: `go run .`
- Test: `go test ./...`
- Stack: go, typescript (Gin, GORM, React, Vite). Difficulty for a non-developer with an AI: **moderate**. A Go back end that embeds a React front end. Most personal changes are chore settings and notifications; new features touch both sides.

## Customisation points (settings → extend → code)
- **chores-and-rotation** [settings]: Who does what, how often, and how it rotates. → `Add chore → Schedule and Assignee rules`
- **circles-and-rewards** [settings]: Shared household groups and what points can buy. → `Circle settings, Points and Rewards`
- **notifications** [settings]: Reminder channels and timing. → `Settings → Notifications`
- **theme** [extend]: Colours and layout. → `frontend/src/ theme files`
- **go-backend** [code]: New rules, notifications and points logic. → `internal/chore, internal/notifier, internal/points`

## Must keep working
- Database migrations in migrations/. Add new ones; never edit old ones.
- Authentication and circle membership checks.
- The scheduler that creates the next chore occurrence.

## Staying updatable
Prefer settings and notifications. Add Go code in new packages under internal/ and keep front-end changes in new components.

## Data, costs and safety
- Personal data: **yes**. Stored in: SQLite database in /donetick-data (Docker volume) or Postgres. Back up the data volume. It holds names, chores and points.
- Service: Notifications (Telegram, Pushover or other chat) (optional, free): Reminders when a chore is due.
- Setting `DT_ENV`: Set to selfhosted to use the self-hosted configuration.
- Setting `DT_SQLITE_PATH`: Where the SQLite database file lives.
- Setting `TZ`: Your time zone so reminders arrive at the right time.
- It stores names and routines of your household. Keep it behind a login and HTTPS if public.
- Don't paste notification tokens into an AI chat.

---

# Customising Donetick

Donetick is a single Go service with the React app built into it. Settings cover most households, so reach for code only when a rule or screen is missing.

## How the code is laid out

| You want to change… | Look in |
|---|---|
| Chore rules and scheduling | internal/chore/ |
| Points and rewards | internal/points/ and internal/reward/ |
| Notifications | internal/notifier/ |
| Users, circles and auth | internal/user/, internal/circle/, internal/auth/ |
| Database setup and migrations | internal/database/ and migrations/ |
| Web app | frontend/src/ |
| Config | config/ |

## Use the gentlest change first

1. **Settings (no code):** chores, circles, points, rewards and notifications.
2. **Extend:** the API and webhooks for other tools.
3. **Code:** Go packages and React components.

## Recipes

- **New reminder rule:** look in `internal/notifier` and add the rule beside the existing ones.
- **New field on a chore:** add a migration, update the model, expose it through the chore handler, then add it to the form in `frontend/src`.

## Running and checking your changes

- `go test ./...` for the back end.
- Build the front end with `npm run build` in `frontend/`, then run `go run .`.
- Create a rotating chore and complete it twice to check it hands over.

## Pitfalls

- Rebuild the front end after changing it. The Go binary embeds the built files.
- Don't commit the SQLite database.

---
Machine-readable: [bespoke.yaml](https://handoff.bespokeai.software/p/donetick/1291130/r2/bespoke.yaml) · Hosting options: [hosting.md](https://handoff.bespokeai.software/p/donetick/1291130/r2/hosting.md) · Agent skill: [SKILL.md](https://handoff.bespokeai.software/p/donetick/1291130/r2/SKILL.md)
