Skip to main content
The context command helps you recover your work context after time away, context switching, or returning to a project. It visualizes your recent activity from saved journal snapshots.

Quick Start

Recover your work context from the last 7 days:
devdaily context
Get an AI-powered โ€œwhere did I leave off?โ€ summary:
devdaily context --ai

How It Works

1

Retrieve Snapshots

Pulls saved journal snapshots from the specified date range.
2

Analyze Activity

Shows current branch, active branches with uncommitted work, and recent activity timeline.
3

Display Context

Renders PRs, tickets, work areas, and progression across days.
4

AI Summary (Optional)

Generates a concise briefing of what you were working on and suggested next steps.
Context recovery requires journal snapshots. If you havenโ€™t taken snapshots yet, the command will create one for you automatically.

Command Options

Time Range

OptionDescriptionDefault
-d, --days <number>Number of days to look back7
--date <date>Show context for specific date (YYYY-MM-DD)-
--from <date>Start date for range (YYYY-MM-DD)-
--to <date>End date for range (YYYY-MM-DD)-
# Default: last week
devdaily context

Project Filtering

OptionDescription
-p, --project <id>Filter by project identifier
--all-projectsShow context across all tracked projects
# Single project
devdaily context --project my-api

# All projects
devdaily context --all-projects

Display Options

OptionDescription
--aiGenerate AI-powered โ€œwhere did I leave off?โ€ summary
--branchesShow detailed active branch status
--rawOutput raw context data (no formatting)
--no-copyDonโ€™t copy AI summary to clipboard
--debugShow debug output
# AI summary of recent work
devdaily context --ai

# Detailed branch information
devdaily context --branches

# Raw data for automation
devdaily context --raw

Output Components

Project Header

  โ”โ”โ” ๐Ÿ“‚ my-api โ”โ”โ”
  /Users/dev/projects/my-api
  3 active days ยท 18 commits
Shows project name, path, active days, and total commits.

Current Branch

  Current branch: feature/oauth2-integration
Displays your current working branch.

Active Branches

Shows branches with work-in-progress:
  Active branches (3):
    โ–ธ feature/oauth2-integration โ† you are here โ†‘5 ahead
      Last: Implement OAuth2 token refresh flow
      Modified: src/auth.ts, src/api/oauth.ts +3 more
    
      feature/dashboard-redesign โ†‘12 ahead โ— uncommitted changes
      Last: Update dashboard layout
      Modified: src/components/Dashboard.tsx
    
      fix/login-redirect
      Last: Fix redirect after successful login
  • โ–ธ - Current branch marker
  • โ† you are here - Youโ€™re currently on this branch
  • โ†‘N ahead - Branch is N commits ahead of base
  • โ— uncommitted changes - Branch has uncommitted work

Activity Timeline

Chronological view of recent work:
  Activity timeline:
    โ”‚ 2024-01-18 (today)  ๐ŸŒฟ feature/oauth2  ๐Ÿ“ 5 ยท 2 PRs ยท +234/-89
    โ”‚   a3f2c91 Implement token refresh endpoint
    โ”‚   b7e1d42 Add OAuth2 configuration
    โ”‚   ... +3 more commits
    โ”‚
    โ”‚ 2024-01-17  ๐ŸŒฟ feature/oauth2  ๐Ÿ“ 8 ยท +456/-123
    โ”‚   c9d4e21 Set up OAuth2 providers
    โ”‚   d2f8a33 Update auth middleware
    โ”‚   e5b3c44 Add OAuth2 database schema
    โ”‚   ... +5 more commits
    โ”‚   ๐Ÿ“Œ Started OAuth2 integration work
    โ•ต

Pull Requests

  Pull Requests:
    โ—‹ #45 Add OAuth2 authentication support (open)
    โ— #43 Refactor error handling (merged)
    โœ• #41 Update API documentation (closed)
  • โ—‹ - Open PR (green)
  • โ— - Merged PR (accent color)
  • โœ• - Closed PR (gray)

Tickets

  Tickets:
    PROJ-123: Implement OAuth2 authentication [in progress]
    PROJ-124: Fix login redirect bug [done]

Work Areas

Bar chart showing time distribution:
  Work areas:
    backend        โ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–‘โ–‘โ–‘โ–‘ 78%
    tests          โ–ˆโ–ˆโ–ˆโ–ˆโ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘ 18%
    docs           โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘โ–‘  4%

AI-Powered Summary

Add --ai to get a concise briefing:
devdaily context --ai

Example AI Output

โ•ญโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ•ฎ
โ”‚ ๐Ÿง  Where You Left Off                           โ”‚
โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
โ”‚                                                 โ”‚
โ”‚ **What I was working on**                       โ”‚
โ”‚ OAuth2 authentication integration for the API.  โ”‚
โ”‚ Started 3 days ago, made steady progress on     โ”‚
โ”‚ token management and provider configuration.    โ”‚
โ”‚                                                 โ”‚
โ”‚ **Current state**                               โ”‚
โ”‚ - โœ… OAuth2 providers configured                 โ”‚
โ”‚ - โœ… Token refresh endpoint implemented          โ”‚
โ”‚ - โณ PR #45 in review                            โ”‚
โ”‚ - โณ Tests need to be written                    โ”‚
โ”‚                                                 โ”‚
โ”‚ **Open threads**                                โ”‚
โ”‚ - Branch: feature/oauth2-integration (5 ahead)  โ”‚
โ”‚ - Uncommitted changes in src/auth.ts            โ”‚
โ”‚ - PR feedback pending                           โ”‚
โ”‚                                                 โ”‚
โ”‚ **Suggested next steps**                        โ”‚
โ”‚ 1. Address PR review feedback                   โ”‚
โ”‚ 2. Write unit tests for token refresh           โ”‚
โ”‚ 3. Commit uncommitted auth changes              โ”‚
โ•ฐโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ•ฏ
The AI analyzes:
  • Main work themes over the period
  • Whatโ€™s completed vs. in progress
  • Open branches and uncommitted work
  • Logical next steps based on patterns
The AI summary is automatically copied to clipboard (disable with --no-copy).

Multi-Project Context

View context across all your projects:
devdaily context --all-projects --days 7
Shows separate sections for each project youโ€™ve worked on.

First-Time Usage

If you havenโ€™t taken snapshots yet:
  No journal entries found. Taking a live snapshot...
  
  โœ“ Snapshot saved for my-api. Future runs will have history.
DevDaily automatically creates your first snapshot and then displays context.

Building Your Journal

To build up context history:
# Take snapshots regularly
devdaily snapshot

# Or enable auto-snapshots in other commands
devdaily standup  # Auto-creates snapshot
devdaily pr       # Auto-creates snapshot

Use Cases

After a Weekend

# Monday morning - what was I doing Friday?
devdaily context --days 3 --ai

After Context Switching

# Just finished working on project A, now back to B
devdaily context --project project-b --ai

After a Vacation

# Back from 2 weeks off
devdaily context --days 14 --branches --ai

Reviewing Old Work

# What was I working on in mid-January?
devdaily context --from 2024-01-10 --to 2024-01-20

Daily Standup Prep

# Quick context before standup meeting
devdaily context --days 1 --ai

Detailed Branch View

Use --branches to see all active branches, not just those with uncommitted work:
devdaily context --branches
Shows:
  • All branches with recent commits
  • Last commit message per branch
  • Files modified in each branch
  • Commits ahead of base

Raw Context Mode

For automation and integrations:
devdaily context --raw
Outputs the raw journal entries in a structured format:
=== 2024-01-18 ===
Project: my-api
Branch: feature/oauth2-integration
Commits:
- a3f2c91: Implement token refresh endpoint
- b7e1d42: Add OAuth2 configuration
...

Example Workflows

Quick Morning Check

# See what I worked on yesterday
devdaily context --days 1

Deep Dive Recovery

# Full context with AI guidance
devdaily context --days 14 --branches --ai

Project-Specific Recovery

# What was happening in the API project?
devdaily context --project my-api --ai

Export for Documentation

# Get raw data for notes
devdaily context --raw > context.txt

Configuration

Customize in .devdaily.json:
{
  "output": {
    "copyToClipboard": true
  }
}

Troubleshooting

If you see โ€œNo work context found for the specified periodโ€:
  1. Take snapshots to build your journal:
    devdaily snapshot
    
  2. Look back further:
    devdaily context --days 30
    
  3. View all snapshots:
    devdaily snapshot --list
    
Journal snapshots are only as complete as the data saved:
  • Take snapshots regularly (daily or after major work)
  • Enable auto-snapshots (enabled by default in standup, pr, week)
  • Use --debug to see what data is available
Ensure GitHub Copilot CLI is installed:
gh extension install github/gh-copilot