Prefix
Certainly! Here's a brief explanation of the GitHub commit prefixes you're using:
- feat:
Indicates a new feature added to the codebase. Use this for significant changes that introduce new functionality. -
Example:
feat: add user login feature
-
fix:
Used when fixing a bug. This is for any code changes that address a problem or bug in the code. -
Example:
fix: correct login validation error
-
chore:
Refers to routine tasks or changes that don't modify application functionality. This could include maintenance tasks, dependency updates, or refactoring code that doesn’t affect the app’s behavior. -
Example:
chore: update dependencies
-
docs:
Used for documentation changes. This includes updating or adding documentation, such as README files, comments, or inline documentation. - Example:
docs: update API usage in README
Additional Common Prefixes:
- style:
Used for changes that do not affect the meaning of the code (white-space, formatting, missing semi-colons, etc.). -
Example:
style: format code with Prettier
-
refactor:
A code change that neither fixes a bug nor adds a feature, but improves code structure or readability. -
Example:
refactor: simplify login logic
-
test:
For adding or updating tests. This is useful when writing new tests or modifying existing ones. -
Example:
test: add unit tests for login feature
-
perf:
Indicates a code change that improves performance. Use this for optimizations that enhance the efficiency of the application. -
Example:
perf: improve login speed by optimizing query
-
ci:
Used for Continuous Integration changes, like updating configuration files for build systems or adding CI/CD pipelines. -
Example:
ci: configure Travis CI for testing
-
build:
Refers to changes that affect the build system or external dependencies (e.g., gulp, npm).- Example:
build: update webpack configuration
- Example:
These prefixes follow the Conventional Commits specification and help in maintaining a clean and structured commit history.