Skip to content

Second user#1

Merged
Lingnik merged 2 commits intoLingnik:mainfrom
tednaleid:second-user
Apr 7, 2026
Merged

Second user#1
Lingnik merged 2 commits intoLingnik:mainfrom
tednaleid:second-user

Conversation

@tednaleid
Copy link
Copy Markdown
Contributor

If you're not interested in pull requests, I'm good with you closing this :D.

I'd also be willing to split this up into 2 PRs if you'd prefer as it is kind of 2 different things.

I ended up getting use out of this today and I think it's a neat tool!

I'm a big fan of justfile and uv to make it easy for me (and claude) to quickly install/use things. Most of the additions are the uv.lock file.

Summary

Two commits that normalize the project tooling and add features to cchat list.

Commit 1: Add uv/just tooling, dev dependencies, and type cleanup

  • Add justfile with install/test/lint/typecheck/pre-commit recipes
  • Add [project.optional-dependencies] for serve (fastapi + uvicorn) and [dependency-groups] for dev (pytest)
  • Update README with install and development instructions
  • Update cchat serve error message to reference uv instead of pip
  • Migrate FastAPI lifecycle from deprecated on_event to lifespan context manager
  • Fix type annotations and remove unused imports across codebase

Commit 2: Add configurable list columns, session names, and workspace display

  • Add -f/--fields flag to cchat list for choosing which columns to display
  • Support - prefix to remove fields from defaults (e.g. -f=-project,-tokens) - need to use -f= or --fields= when negative.
  • All fields shown by default; use --fields to narrow when needed
  • Add workspace column showing cwd basename (repo or worktree directory name)
  • project column retains the original raw project key behavior
  • Auto-size snippet column to fit the terminal width; skip truncation when piped
  • Show conversation names from ~/.claude/sessions/

My work laptop is a 13" macbook pro, so the text was wrapping at all but the smallest sizes. This helps me fit it nicely on any monitor. I also wanted the name field for those sessions that I /rename

Usage examples:

# all columns shown by default
cchat list --limit 3
WORKSPACE  PROJECT                                                         SNIPPET                                                       FIRST        LAST         TURNS  AGENTS  MODEL    TOKENS  COST     NAME                    SLUG
---------  --------------------------------------------------------------  ------------------------------------------------------------  -----------  -----------  -----  ------  -------  ------  -------  ----------------------  ---------------------------
cchat      -Users-tednaleid-Library-CloudStorage-Dropbox-code-other-cchat  take a look at this project, how do we run it? I'd like a sy  04-07 12:50  04-07 22:34  25     0       opus4.6  7.2M    $5.37                            sunny-percolating-candle
quoth      -Users-tednaleid-Library-CloudStorage-Dropbox-code-quoth        <local-command-caveat>Caveat: The messages below were genera  04-07 00:44  04-07 20:16  12     7       opus4.6  65.9M   $46.16                           steady-scribbling-curry
veer       -Users-tednaleid-Library-CloudStorage-Dropbox-code-veer         <command-message>veer</command-message> <command-name>/veer<  04-07 00:47  04-07 02:30  12     3       opus4.6  9.2M    $9.06                            temporal-juggling-peacock

# remove specific columns from defaults
cchat list -f=-project,-tokens,-snippet,-name --limit 3
WORKSPACE  FIRST        LAST         TURNS  AGENTS  MODEL    COST     SLUG
---------  -----------  -----------  -----  ------  -------  -------  ---------------------------
cchat      04-07 12:50  04-07 22:42  27     0       opus4.6  $5.77    sunny-percolating-candle
quoth      04-07 00:44  04-07 20:16  12     7       opus4.6  $46.16   steady-scribbling-curry
veer       04-07 00:47  04-07 02:30  12     3       opus4.6  $9.06    temporal-juggling-peacock

# show only specific fields
cchat list -f last,cost,slug --limit 3
LAST         COST     SLUG
-----------  -------  ---------------------------
04-07 22:42  $5.77    sunny-percolating-candle
04-07 20:16  $46.16   steady-scribbling-curry
04-07 02:30  $9.06    temporal-juggling-peacock

Available fields: workspace, project, snippet, first, last, turns, agents, model, tokens, cost, name, slug.

Test plan

  • just check passes (tests, lint, typecheck)
  • cchat list displays all columns by default
  • cchat list -f -project,-tokens removes those columns
  • cchat list -f name,cost,slug shows only specified columns
  • cchat list | head does not truncate snippet
  • cchat serve starts without errors after just install

tednaleid and others added 2 commits April 7, 2026 17:10
Set up justfile with install/test/lint/typecheck/pre-commit recipes.
Add serve optional dependency (fastapi + uvicorn) and pytest dev group.
Update README with install and development instructions. Migrate FastAPI
lifecycle to lifespan context manager. Fix type annotations and remove
unused imports across codebase.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Make list columns configurable with --fields and auto-size snippet to
terminal width. Show conversation names from ~/.claude/sessions/.
Display friendly project names using cwd basename instead of raw keys.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@Lingnik Lingnik merged commit 0f97923 into Lingnik:main Apr 7, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants