Thank you for your interest in contributing to ah! We welcome various forms of contributions, including bug reports, feature requests, code submissions, documentation improvements, and more.
Please read and follow our Code of Conduct to maintain a friendly and professional environment.
- Search existing Issues to avoid duplicates
- Use the Bug Report template to create a new issue
- Include the following information:
- Steps to reproduce
- Expected vs actual behavior
- Environment info (OS, Nix version, Rust version)
- Relevant log output
- Search existing Issues and PRs
- Use the Feature Request template to create a new issue
- Clearly describe the use case and expected behavior
# Clone the project
git clone https://github.com/z1-0/ah.sh.git
cd ah
# Enter development environment
nix develop
# Or use cargo
cargo build- Format code with
cargo fmt - Run
cargo clippyto check for warnings - Keep code concise, following Rust functional programming patterns
- Use the
fp-corelibrary for functional utilities
We follow Conventional Commits:
<type>: <description>
[optional body]
[optional footer]
Types:
feat: New featurefix: Bug fixrefactor: Code refactoringdocs: Documentation updatesstyle: Code style (formatting, no functionality change)test: Test relatedchore: Build process or tooling changes
Example:
feat(session): add session restore by index
Add ability to restore sessions using index number
in addition to session ID.
Closes #123
- Fork this repository
- Create a feature branch:
git checkout -b feat/my-feature - Make your changes and commit
- Push branch:
git push -u origin feat/my-feature - Create a Pull Request
- Wait for code review and merge
- All tests pass (
cargo test) - No clippy warnings (
cargo clippy -- -D warnings) - Code is formatted (
cargo fmt) - Include appropriate tests (if applicable)
- Update relevant documentation
- Fix spelling and grammar errors
- Improve clarity of existing documentation
- Translate documentation to other languages
- Add missing examples
src/
├── cli/ # Command-line parsing
├── provider/ # Provider abstraction and implementation
├── session/ # Session management
├── cmd.rs # Shell command execution
├── manager.rs # Core business orchestration
└── paths.rs # Path utilities
# Run all tests
cargo test
# Run specific test
cargo test <test_name>
# Run tests in release mode
cargo test --release# Debug build
cargo build
# Release build
cargo build --release
# Run locally
cargo run -- --help
cargo run -- use rust goBy contributing code, you agree to release your contributions under the project's license (MIT).