{"id":31522656,"url":"https://github.com/anqorithm/git-flow-strategy","last_synced_at":"2026-04-18T07:33:24.029Z","repository":{"id":305203359,"uuid":"1022261778","full_name":"anqorithm/git-flow-strategy","owner":"anqorithm","description":"This project uses the GitFlow branching model to manage features, bugfixes, releases, and hotfixes for a simple calculator class. This document explains the workflow, branch types, and best practices for contributing and maintaining code quality.","archived":false,"fork":false,"pushed_at":"2025-07-18T18:59:40.000Z","size":143,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-04-04T17:29:42.576Z","etag":null,"topics":["branch-strategies","branching-strategy","git","gitflow","github","gitworkflow"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/anqorithm.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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,"zenodo":null}},"created_at":"2025-07-18T18:23:36.000Z","updated_at":"2025-07-18T18:58:56.000Z","dependencies_parsed_at":"2025-07-18T22:23:13.459Z","dependency_job_id":"fd591f5d-633b-4b25-9107-f0fa63002ee6","html_url":"https://github.com/anqorithm/git-flow-strategy","commit_stats":null,"previous_names":["anqorithm/git-flow-strategy"],"tags_count":4,"template":false,"template_full_name":null,"purl":"pkg:github/anqorithm/git-flow-strategy","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/anqorithm%2Fgit-flow-strategy","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/anqorithm%2Fgit-flow-strategy/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/anqorithm%2Fgit-flow-strategy/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/anqorithm%2Fgit-flow-strategy/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/anqorithm","download_url":"https://codeload.github.com/anqorithm/git-flow-strategy/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/anqorithm%2Fgit-flow-strategy/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31961291,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-18T00:39:45.007Z","status":"online","status_checked_at":"2026-04-18T02:00:07.018Z","response_time":103,"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":["branch-strategies","branching-strategy","git","gitflow","github","gitworkflow"],"created_at":"2025-10-03T15:39:39.862Z","updated_at":"2026-04-18T07:33:24.023Z","avatar_url":"https://github.com/anqorithm.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# GitFlow Strategy\n\n## 1. Introduction\n\nThis project uses the **GitFlow** branching model to manage features, bugfixes, releases, and hotfixes for a simple calculator class. This document explains the workflow, branch types, and best practices for contributing and maintaining code quality.\n\n---\n\n## 2. Branching Model Overview\n\n- **main**: Production-ready code.\n- **dev**: Latest development changes.\n- **feature/**: New features (e.g., `feature/add-method`).\n- **bugfix/**: Non-production bug fixes (e.g., `bugfix/handle-negative-input`).\n- **release/**: Release preparation (e.g., `release/v1.0.0`).\n- **hotfix/**: Urgent production fixes (e.g., `hotfix/divide-by-zero`).\n\n---\n\n## 3. GitFlow Example Diagram\n\n```mermaid\ngitGraph\n    commit\n    branch dev\n    checkout dev\n    commit\n\n    %% First release: add \u0026 subtract\n    branch feature/add-method\n    checkout feature/add-method\n    commit\n    checkout dev\n    merge feature/add-method\n\n    branch feature/subtract-method\n    checkout feature/subtract-method\n    commit\n    checkout dev\n    merge feature/subtract-method\n\n    branch release/v1.0.0\n    checkout release/v1.0.0\n    commit id: \"Release prep v1.0.0\"\n\n    checkout main\n    commit id: \"Tag: v1.0.0\"\n    merge release/v1.0.0\n\n    checkout dev\n    merge release/v1.0.0\n\n    %% Second release: multiply \u0026 divide\n    branch feature/multiply-method\n    checkout feature/multiply-method\n    commit\n    checkout dev\n    merge feature/multiply-method\n\n    branch feature/divide-method\n    checkout feature/divide-method\n    commit\n    checkout dev\n    merge feature/divide-method\n\n    branch release/v1.1.0\n    checkout release/v1.1.0\n    commit id: \"Release prep v1.1.0\"\n\n    checkout main\n    merge release/v1.1.0\n    commit id: \"Tag: v1.1.0\"\n\n    checkout dev\n    merge release/v1.1.0\n\n    %% Hotfix after v1.1.0\n    branch hotfix/divide-by-zero\n    checkout hotfix/divide-by-zero\n    commit id: \"Fix: divide-by-zero\"\n\n    checkout main\n    merge hotfix/divide-by-zero\n    commit id: \"Tag: v1.1.1\"\n\n    checkout dev\n    merge hotfix/divide-by-zero\n\n    %% Bugfix example\n    checkout dev\n    branch bugfix/handle-negative-input\n    checkout bugfix/handle-negative-input\n    commit id: \"Fix: handle negative input\"\n    checkout dev\n    merge bugfix/handle-negative-input\n```\n\n---\n\n## 4. Branch Usage Summary\n\n| Branch Type   | Purpose                                 | Created From | Merged Into      | Example Name                  |\n|---------------|-----------------------------------------|--------------|------------------|-------------------------------|\n| main          | Production releases                     | release/hotfix | —                | main                          |\n| dev       | Latest development                      | feature/bugfix/release | —         | dev                       |\n| feature/      | New features                            | dev      | dev          | feature/add-method            |\n| bugfix/       | Non-production bug fixes                | dev      | dev          | bugfix/handle-negative-input  |\n| release/      | Release preparation                     | dev      | main, dev    | release/v1.0.0                |\n| hotfix/       | Urgent production bug fixes             | main         | main, dev    | hotfix/divide-by-zero         |\n\n---\n\n## 6. How to Run Tests\n\n```bash\n$ uv venv\n$ source .venv/bin/activate\n$ uv sync\n$ pytest tests/test_calculator.py -v\n```\n\n---\n\n## 8. All Bug Handling Scenarios in GitFlow\n\n| # | Scenario                                | Branch to Create                | Base Branch      | Merge Back Into        | Notes                                                      |\n| - | --------------------------------------- | ------------------------------- | ---------------- | ---------------------- | ---------------------------------------------------------- |\n| 1 | Bug in feature/* (in-progress feature)   | Fix directly in `feature/*`     | `feature/*`      | `dev` (via PR)         | Not merged yet, so fix inline                              |\n| 2 | Bug in dev (pre-production bug)          | `bugfix/*`                      | `dev`            | `dev` (via PR)         | Used during development/testing                            |\n| 3 | Bug in release/* (during regression)     | `bugfix/release-*` (if critical) | `release/*`      | `release/*` (then main, dev) | Critical: branch+fix; Non-critical: register for next sprint |\n| 4 | Bug in main (production bug)             | `hotfix/*`                      | `main`           | `main`, `dev` (via PR) | Urgent fixes, patch tagged (e.g., v1.1.1)                  |\n\n**Note:**\n- For critical bugs found during release regression, create a `bugfix/release-*` branch from the release branch, fix, and merge back into the release branch. After release, merge the release branch into both `main` and `dev`.\n- For non-critical bugs, register the issue for the next sprint and do not fix in the release branch.\n\n## 9. GitFlow Graph\n\n![GitFlow Graph](assets/gitflow-graph.png)","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fanqorithm%2Fgit-flow-strategy","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fanqorithm%2Fgit-flow-strategy","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fanqorithm%2Fgit-flow-strategy/lists"}