This repository was archived by the owner on Dec 8, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
Style Guide
Lani edited this page Jan 25, 2024
·
2 revisions
About This File
The purpose of this file is to provide guidance, examples, and templates for commit messages and branch names. If you are a development team member, please keep this file updated.
Commit Messages
When creating commit messages for the Cooper Casino backend, follow these guidelines:
- Be Clear and Concise: Write commit messages that are clear and concise, summarizing the purpose of the commit.
- Start with a Verb: Begin the commit message with a verb in the imperative mood to describe what the commit does. For example: "Add," "Fix," "Update," "Remove," etc.
- Use Present Tense: Write commit messages in the present tense, as if you are describing the current state of the codebase.
- Provide Context: Include relevant information to provide context about the changes made. This may include mentioning the feature, bug, task, or issue the commit addresses.
- Limit Line Length: Keep commit messages less than 60 characters to ensure readability in various Git tools.
Examples:
- Add user authentication feature
- Fix bug causing incorrect calculations
- Update README with installation instructions
- Remove obsolete code
- Refactor database queries for improved performance
- _Merge pull request #123: Implement search functionality
Template:
[{Make:Create:Added:Changed}] [What you Changed]
Branch Names
When creating branch names for the Cooper Casino backend, follow these guidelines:
- Be descriptive: Choose branch names that indicate the purpose or feature being worked on.
- Use lowercase letters and hyphens: Separate words in branch names with hyphens for improved readability.
- Include relevant information: If the branch relates to a specific task, include a task or issue reference in the branch name.
- Make it short: Limit the branch name to consist of only one to two words.
- Commit Name Root: user branch - user, feature branch - feature, bug fix - fix. These should have issues attached to them.
Examples:
- feature/user-authentication
- user/laniw/issue-123
- /user/secureshellprotocol/fix/database-optimization