{"id":26902487,"url":"https://github.com/silent-watcher/branch-lint","last_synced_at":"2025-09-21T00:34:18.529Z","repository":{"id":284742850,"uuid":"955911345","full_name":"Silent-Watcher/branch-lint","owner":"Silent-Watcher","description":"A CLI tool to validate Git branch names using Conventional Branch guidelines.","archived":false,"fork":false,"pushed_at":"2025-04-30T09:10:56.000Z","size":78,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-09-20T01:31:44.252Z","etag":null,"topics":["cli","conventional-branch","git","version"],"latest_commit_sha":null,"homepage":"https://www.npmjs.com/package/validate-branch","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Silent-Watcher.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2025-03-27T11:52:16.000Z","updated_at":"2025-08-29T05:26:36.000Z","dependencies_parsed_at":"2025-03-27T13:34:22.521Z","dependency_job_id":null,"html_url":"https://github.com/Silent-Watcher/branch-lint","commit_stats":null,"previous_names":["silent-watcher/branch-lint"],"tags_count":6,"template":false,"template_full_name":null,"purl":"pkg:github/Silent-Watcher/branch-lint","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Silent-Watcher%2Fbranch-lint","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Silent-Watcher%2Fbranch-lint/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Silent-Watcher%2Fbranch-lint/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Silent-Watcher%2Fbranch-lint/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Silent-Watcher","download_url":"https://codeload.github.com/Silent-Watcher/branch-lint/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Silent-Watcher%2Fbranch-lint/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":276179476,"owners_count":25598567,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-09-20T02:00:10.207Z","response_time":63,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cli","conventional-branch","git","version"],"created_at":"2025-04-01T09:43:34.076Z","updated_at":"2025-09-21T00:34:18.479Z","avatar_url":"https://github.com/Silent-Watcher.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# validate-branch\n\n[![Checked with Biome](https://img.shields.io/badge/Checked_with-Biome-60a5fa?style=flat\u0026logo=biome)](https://biomejs.dev)\n[![Commitizen friendly](https://img.shields.io/badge/commitizen-friendly-brightgreen.svg)](http://commitizen.github.io/cz-cli/)\n[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)\n\nA CLI tool to validate Git branch names using [Conventional Branch](https://conventional-branch.github.io/) guidelines. This package ensures that your branch names follow consistent naming conventions—supporting core branches like main, master, and develop, as well as structured feature, bugfix, hotfix, and release branches.\n\n## Table of Contents\n\n- [validate-branch](#validate-branch)\n\t- [Table of Contents](#table-of-contents)\n\t- [Installation](#installation)\n\t- [Usage](#usage)\n\t\t- [Command Line](#command-line)\n\t- [Git Hooks Integration](#git-hooks-integration)\n\t- [Branch Naming Conventions](#branch-naming-conventions)\n\t- [Issues and Contributing](#issues-and-contributing)\n\t- [License](#license)\n\t- [Contact](#contact)\n\n## Installation\n\nInstall the package globally using npm:\n\n```sh\nnpm install -g validate-branch\n```\n\nOr add it as a development dependency in your project:\n\n```sh\nnpm install --save-dev validate-git-branch\n```\n\n## Usage\n\n### Command Line\nOnce installed, run the CLI command in your Git repository:\n\n```sh\nvalidate-branch\n```\n\nThe tool will fetch the current Git branch name and validate it against the conventional naming rules. If the branch name is valid, you'll see a success message; otherwise, an error message will guide you to use the correct format.\n\n## Git Hooks Integration\n\nYou can integrate this tool with Git hooks to enforce branch naming on every commit or push. For example, using Husky:\n\n```sh\nnpx husky add .husky/pre-push \"validate-branch\"\n```\n\n## Branch Naming Conventions\n\nYour branches should follow one of the following patterns:\n- Core Branches:\n \t- `main`\n \t- `master`\n \t- `develop`\n\n- Feature, Bugfix, and Hotfix Branches:\n  - `feature/branch-name`\n  - `bugfix/branch-name`\n  - `hotfix/branch-name`\n\n- Release Branches:\n \t- `release/branch-name`\n \t- Release branches may include dots (e.g., release/v1.2.0)\n\nThe tool uses a refined regular expression to ensure that only the proper characters and structure are allowed for each branch type.\n\n## Issues and Contributing\n\nIf you encounter a bug or want to see something added/changed, please go ahead and open an [issue](https://github.com/Silent-Watcher/branch-lint/issues)\n! If you need help with something, feel free to start a [discussion](https://github.com/Silent-Watcher/branch-lint/discussions/new)!\n\n## License\n\nThis project is licensed under the MIT License.\n\n## Contact\n\nFor support or any questions, please open an issue in the GitHub repository or contact \u003cbackendwithali@gmail.com\u003e.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsilent-watcher%2Fbranch-lint","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsilent-watcher%2Fbranch-lint","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsilent-watcher%2Fbranch-lint/lists"}