- Añadido archivo LICENSE.md con texto de la licencia GNU Affero General Public License v3.0 - Actualizado .gitignore para incluir LICENSE.md en el seguimiento de Git - Asegurado que el archivo de licencia sea rastreado por Git 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
69 lines
3.3 KiB
Markdown
69 lines
3.3 KiB
Markdown
# MRDevs Tools Development Guide
|
|
|
|
## Build & Installation Commands
|
|
- **`bin/bootstrap.sh`**: Installs basic tools and container management setup.
|
|
- **`bin/update.sh`**: Updates the development environment.
|
|
- **`bin/cortana_install.sh`**: Installs the Claude Code CLI.
|
|
- **`bin/cortana_install.sh -u`**: Uninstalls the Claude Code CLI.
|
|
|
|
## Code Style Guidelines
|
|
|
|
### Shell Scripts
|
|
- **License Header**: Always include a license header with copyright information (AGPL).
|
|
- **Commenting**:
|
|
- Include the **Modified Date** in the comments.
|
|
- Document the **purpose of each function** and provide **usage examples** in the script header.
|
|
- **Modularity**:
|
|
- Use functions to ensure script modularity.
|
|
- Group related tasks in functions for better readability and maintenance.
|
|
- **Variable Naming**:
|
|
- Use **UPPERCASE** for constants and environment variables.
|
|
- Use **snake_case** for general variables and function names.
|
|
- **Error Handling**: Ensure that errors are handled properly using **exit codes** and log relevant details.
|
|
- **Versioning**: Include the script version (from the `bin/config/version` file) in the script header, e.g., `#Version 1.0.0`.
|
|
|
|
### Python Scripts
|
|
- Adhere to Python's PEP-8 coding style.
|
|
- Include proper **docstrings** for all functions and classes.
|
|
- Always handle exceptions using `try-except` blocks, and ensure the script exits with appropriate status codes.
|
|
|
|
## Development Practices
|
|
|
|
- **Common Libraries**:
|
|
- Use `bin/lib/base.lib` for commonly shared functions.
|
|
- Use `bin/lib/developers.lib` for developer-specific utilities.
|
|
- Use `bin/lib/clonsole.lib` for dialog-based functions.
|
|
- **Multilingual Support**:
|
|
- Store message files in `bin/msg/` to support multiple languages.
|
|
- **Configuration Files**:
|
|
- Store configuration settings in the `bin/config/` directory.
|
|
- **Version Control**:
|
|
- Use descriptive and consistent **commit message prefixes**:
|
|
- `[ADDED]` for new features
|
|
- `[IMPROVED]` for updates or enhancements
|
|
- `[FIXED]` for bug fixes
|
|
- `[SOPS]` for secrets management updates
|
|
- `[INIT]` for initial commits
|
|
- **Container Management**:
|
|
- Prefer **Podman** over Docker for container management.
|
|
- **Directory Structure**:
|
|
- Place all shell scripts (`.sh`) and Python scripts (`.py`) in the `bin/` directory unless specified otherwise.
|
|
|
|
## Authorship Policy
|
|
|
|
- For Python files, use `bin/config/python.header` as a template for the comment header.
|
|
- For Bash files, use `bin/config/bash.header` as a template for the comment header.
|
|
- **Author Information**: For new projects generated by Claude Code, the author should be specified as:
|
|
- `Cortana Rosero One <cortana@rosero.one>`
|
|
- **Generation Reference**: Always include a reference to the Claude Code version used for generation.
|
|
- Example header comment for files generated by Cortana:
|
|
```bash
|
|
# [Author] Cortana Rosero One <cortana@rosero.one>
|
|
# [Generated] Created by Claude Code (claude-3-7-sonnet-20250219)
|
|
```
|
|
|
|
## Additional Notes
|
|
- Maintain **clarity and consistency** throughout the codebase to ensure that the development process remains smooth and maintainable.
|
|
- Regularly **sync** with the main repository to ensure up-to-date dependencies and standards are being followed.
|
|
- Encourage collaboration and **peer review** to improve code quality.
|
|
|