Skip to content

feat(config): Add support for env var configuration#896

Open
keithy wants to merge 2 commits intosipeed:mainfrom
keithy:support-env-vars
Open

feat(config): Add support for env var configuration#896
keithy wants to merge 2 commits intosipeed:mainfrom
keithy:support-env-vars

Conversation

@keithy
Copy link

@keithy keithy commented Feb 28, 2026

📝 Description

This commit introduces support for two environment variables, allowing users to override the default paths for picoclaw's home directory and configuration file.

  • PICOCLAW_CONFIG: Directly specifies the path to the config.json file. This is initialised first, takes precedence over the hardcoded path, and is ideal for containerized deployments or custom config management.

  • PICOCLAW_HOME: Overrides the root directory for all picoclaw data, (except the config) (e.g., ~/.picoclaw). This is useful for portable installations or placing data in non-standard locations.

This change provides greater flexibility for running picoclaw in various environments without being tied to the default home directory structure.

🗣️ Type of Change
[ ] 🐞 Bug fix (non-breaking change which fixes an issue)
[x] ✨ New feature (non-breaking change which adds functionality)
[ ] 📖 Documentation update
[ ] ⚡ Code refactoring (improved service management)

🤖 AI Code Generation
[x] 👨‍💻 Mostly Human-written (Human lead)

🔗 Related Issue

📚 Technical Context

🧪 Test Environment
Hardware: Rock64 (ARM64)
OS: Debian/Ubuntu (Linux) armbian, mise
Channels: CLI / Local Daemon

☑️ Checklist
[x] My code/docs follow the style of this project.
[x] I have performed a self-review of my own changes.
[x] I have updated the documentation (added systemd instructions).

This commit introduces support for two environment variables,
allowing users to override the default paths for picoclaw's home
directory and configuration file.

- `PICOCLAW_CONFIG`: Directly specifies the path to the `config.json` file.
This is initialised first, takes precedence over the hardcoded path, and is ideal
for containerized deployments or custom config management.

- `PICOCLAW_HOME`: Overrides the root directory for all picoclaw data, (except the config)
(e.g., `~/.picoclaw`). This is useful for portable installations or placing
data in non-standard locations.

This change provides greater flexibility for running picoclaw in various environments without
being tied to the default home directory structure.
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.

1 participant