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
9 changes: 9 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -32,5 +32,14 @@ Thumbs.db
.ruff_cache/
.pytest_cache/

# Node (for Puppeteer testing)
node_modules/
package.json
package-lock.json

# Screenshots (debug artifacts)
Screenshot.png

# Other
start.sh
.env
45 changes: 42 additions & 3 deletions CLAUDE.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,16 +20,55 @@ All work must align with these principles (in priority order):
2. **User Data Ownership** - Data lives in user's Google Sheets, not our servers
3. **Simplicity & Focus** - Pomodoro timer and time tracking only, no feature creep
4. **Timer Agnosticism** - Internal timer and external physical timers are equally supported
5. **Offline-First** - SQLite cache for all reads, background sync to Google Sheets
5. **Offline-First** - IndexedDB cache for all reads, background sync to Google Sheets
6. **Container-Ready** - Single container, env var config, no persistent volumes

## Technology Stack

- **Backend**: Python 3.x / Flask
- **Frontend**: Vanilla HTML/CSS/JavaScript (no build step)
- **Local Storage**: SQLite
- **Local Storage**: IndexedDB (browser-side)
- **Cloud Storage**: Google Sheets API v4
- **Auth**: Google OAuth 2.0
- **Auth**: Google OAuth 2.0 (credentials stored in IndexedDB, server is stateless)

## Local Development

### Container Names (Standardized)

Always use these exact names for local development:

- **Image**: `acquacotta:dev`
- **Container**: `acquacotta-dev`

### Build and Run Commands

```bash
# Build the dev image
podman build -t acquacotta:dev .

# Stop and remove existing container, then run new one
# Note: Map host port 5000 to container port 80 (Apache reverse proxy)
podman stop acquacotta-dev 2>/dev/null; podman rm acquacotta-dev 2>/dev/null
podman run -d --name acquacotta-dev -p 5000:80 --env-file .env acquacotta:dev

# View logs
podman logs acquacotta-dev

# One-liner for rebuild and restart
podman build -t acquacotta:dev . && podman stop acquacotta-dev 2>/dev/null; podman rm acquacotta-dev 2>/dev/null; podman run -d --name acquacotta-dev -p 5000:80 --env-file .env acquacotta:dev
```

### Environment Variables (.env)

Required for local development:
```
FLASK_ENV=development
FLASK_SECRET_KEY=dev-secret-key-not-for-production
SESSION_COOKIE_SECURE=false
OAUTH_REDIRECT_BASE=http://localhost:5000
GOOGLE_CLIENT_ID=<your-client-id>
GOOGLE_CLIENT_SECRET=<your-client-secret>
```

## Before Making Changes

Expand Down
Loading