Skip to content

feat: enhanced custom config directory with --config/-c option #46

@lroolle

Description

@lroolle

Description

Enhance custom config directory support with flexible --config/-c option for mounting Claude configuration from custom locations

Type

  • New feature
  • Enhancement

Details

Building on issue #31, implement comprehensive custom config directory support:

  1. Add --config/-c option to claude.sh

    • Default behavior: mount ~/.claude and ~/.claude.json as usual
    • With -c ~/Desktop/claude-config-home/:
      • Create directory if it doesn't exist
      • Mount subdirectories to appropriate locations in container
  2. Directory mapping behavior:

    • ~/Desktop/claude-config-home/.claude → /home/claude/.claude
    • ~/Desktop/claude-config-home/.claude.json → /home/claude/.claude.json
    • Support for other config files as needed
  3. Multiple config profiles support:

    • Allow users to maintain different Claude configurations
    • Easy switching between work/personal profiles
    • Isolation of authentication states

Related Files

  • claude.sh (add --config/-c parameter parsing and mounting logic)
  • docker-entrypoint.sh (update to handle custom config mount points)
  • claude-yolo (pass through --config option)

Test Plan

  • Test default behavior without --config flag
  • Test custom config directory creation if missing
  • Test mounting from existing custom config directory
  • Verify authentication persists in custom location
  • Test switching between multiple config directories
  • Ensure backward compatibility with existing setups
  • Test error handling for invalid paths

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions