quality-code
v1.0.18
Published
A utility to set up Git hooks and configuration files for enforcing branch name validation and commit message linting in a project using popular packages like Husky, Validate Branch Name, and Commitlint. It installs necessary dependencies, creates configu
Downloads
25
Maintainers
Readme
Quality Code
Quality Code is a utility to set up Git hooks and configuration files for enforcing branch name validation and commit message linting in a project using popular packages like Husky, Validate Branch Name, and Commitlint. It installs necessary dependencies, creates configuration files, sets up package.json scripts, and adds Husky hooks. Branch names are validated against a specified pattern, and commit messages are linted based on conventional commit guidelines.
Features
- Validates branch names to follow a specific pattern.
- Enforces commit message format using conventional commit standards.
- Provides hooks for pre-commit checks to ensure code quality before committing.
Installation
To install Quality Code, run the following command:
npm install quality-code
Configuration
Quality Code provides the following configuration files:
.validate-branch-namerc
: Configures the branch name pattern and error message.commitlint.config.js
: Configures the commit message format and rules.
You can modify these files according to your project's requirements.
Contributing
Contributions are welcome! If you encounter any issues or have suggestions for improvement, please open an issue or submit a pull request on the GitHub repository.
License
Quality Code is released under the MIT License.
This project relies on the following packages for its functionality:
- Husky: Git hooks made easy.
- Validate Branch Name: Validate branch names against custom patterns.
- @commitlint/cli: Lint commit messages using conventional commit standards.
- @commitlint/config-conventional: Default configuration for commitlint using conventional commits.
These packages greatly contribute to the features and functionality of Quality Code. We extend our gratitude to their maintainers and contributors for their excellent work.