Project Structure
A ChimeraX bundle project generated by echi init has the following structure:
my-tool/
├── pyproject.toml # Bundle metadata and build config
├── src/
│ ├── __init__.py # Bundle initialization
│ └── cmd.py # Command implementation (varies by bundle type)
├── tests/ # Test files (for echi test)
│ └── test_*.py # pytest test modules
├── scripts/
│ └── smoke.cxc # Smoke test script
└── README.md
Key Files
pyproject.toml
The central configuration file for your bundle. Contains:
- Bundle metadata (name, version, description)
- ChimeraX-specific configuration (commands, tools, etc.)
- Build system configuration
src/
Source code for your bundle. The layout depends on the bundle type:
| Bundle Type | Main Source File |
|---|---|
| command | src/cmd.py |
| tool, tool-html | src/tool.py |
| format | src/open.py |
| fetch | src/fetch.py |
| selector | src/selector.py |
| preset | src/preset.py |
| cpp | src/chimerax/<package>/cmd.py + _extension.cpp |
scripts/smoke.cxc
A ChimeraX command script for quick smoke testing. Run with:
echi test --smoke
tests/
Directory for pytest test files. Run with:
echi test