{"id":14008189,"url":"https://github.com/lesfurets/git-octopus","last_synced_at":"2025-10-12T03:33:14.840Z","repository":{"id":17649743,"uuid":"20454259","full_name":"lesfurets/git-octopus","owner":"lesfurets","description":"The continuous merge workflow","archived":false,"fork":false,"pushed_at":"2019-10-01T12:47:28.000Z","size":1896,"stargazers_count":223,"open_issues_count":12,"forks_count":22,"subscribers_count":41,"default_branch":"master","last_synced_at":"2024-04-14T06:35:49.531Z","etag":null,"topics":["continuous-delivery","git","workflow"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"lgpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/lesfurets.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}},"created_at":"2014-06-03T18:25:55.000Z","updated_at":"2024-01-03T19:47:59.000Z","dependencies_parsed_at":"2022-09-24T00:23:56.616Z","dependency_job_id":null,"html_url":"https://github.com/lesfurets/git-octopus","commit_stats":null,"previous_names":[],"tags_count":10,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lesfurets%2Fgit-octopus","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lesfurets%2Fgit-octopus/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lesfurets%2Fgit-octopus/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lesfurets%2Fgit-octopus/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lesfurets","download_url":"https://codeload.github.com/lesfurets/git-octopus/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247631833,"owners_count":20970069,"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","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":["continuous-delivery","git","workflow"],"created_at":"2024-08-10T11:01:23.383Z","updated_at":"2025-10-12T03:33:09.782Z","avatar_url":"https://github.com/lesfurets.png","language":"Go","funding_links":[],"categories":["Go","Building"],"sub_categories":["Workflows"],"readme":"[![Build Status](https://travis-ci.org/lesfurets/git-octopus.svg?branch=master)](https://travis-ci.org/lesfurets/git-octopus)\n[![codecov](https://codecov.io/gh/lesfurets/git-octopus/branch/master/graph/badge.svg)](https://codecov.io/gh/lesfurets/git-octopus)\n\n# git-octopus\n\u003eThe continuous merge workflow is meant for continuous integration/delivery and is based on feature branching. git-octopus provides git commands to implement it.\n\n## Installation\n\n### Requirements\nRequires git \u003e= 1.8\n\nYou need to have a command `shasum` in the path. This is the case on most unix based systems. If you're on Windows/Cygwin you may have to install it.\n\n### Homebrew\nIf you know and use [Homebrew](http://brew.sh), you just need to do:\n```bash\nbrew update\nbrew install git-octopus\n```\n### RPM package manager\n\nThe packaging is temporarily hosted on [Fedora copr](https://copr.fedorainfracloud.org/coprs/baitaand/git-octopus/build/484097/):\n\n```bash\ndnf copr enable baitaand/git-octopus\ndnf install git-octopus\n```\n\n### From sources\nDownload the latest [release](https://github.com/lesfurets/git-octopus/releases/latest) or clone this repository. Go into the directory and type\n```bash\nmake install\n```\n\nMake sure the installation works\n```bash\ngit octopus -v\n```\n\n\u003eWe respect [semver](http://semver.org/)\n\n## What you'll find\nTwo additionnal git commands : \n\n### git octopus\nExtends `git merge` with branch naming patterns. For instance\n```\ngit octopus features/*\n```\nMerges all branches named features/ into the current branch.\nSee [git-octopus(1)](http://lesfurets.github.io/git-octopus/doc/git-octopus.html).\n\n### git conflict\nAllows you to record conflicts resolutions that `git octopus` can reuse.\nConflicts resolutions are standard refs so they can be pushed/fetched.\nSee the conflicts management section bellow and [git-conflict(1)](http://lesfurets.github.io/git-octopus/doc/git-conflict.html).\n\n## The Continuous Merge\n\n### What is it all about ?\nFeature branching and continuous integration don't live well together. The idea of this project is to reconcile those two by using the mighty power of git.\n\nI gave a talk about why and how to use it at Devoxx France 2015, but it's in french ;) https://www.youtube.com/watch?v=8P0vyWIyAXM\n\n### The branching model\nThe simpliest form of the model is to have a mainline branch, let's call it `master`, and feature branches on top of that master. In a continuous delivery workflow you won't need more than that. \n\n* The `master` branch, or however you call it, is in a ready-to-ship state. Nobody commits on it.\n* A feature branch is a change, as small as possible, that can bring the `master` from a ready-to-ship state to an other.\n\nThis means that all the work is done in feature branches. Don't be afraid to have many, one branch per developer is fine. Keep feature branches independent from each other, that's the key for having a fluent delivery pipe.\n\n### The workflow\n`git octopus` allows you to merge all you feature branches together at any moment so you can have an assembly of all the work that is going on and finally do a continuous integration job on that merge. here's how it works : \n\nA developer pushes a change on his feature branch. There is a job in your continuous integration system that will trigger and do this bash command :\n\n```bash\ngit octopus origin/features/* origin/master \u0026\u0026 git push origin +HEAD:octopus\n```\nThis job computes a merge with all feature branches and the master, and then pushes the result on a branch `octopus` on origin. \nThe new merge commit on `octopus` will now trigger an other job that will build and deploy this merge on your test servers etc ...\nNote that the octopus merge is not kept in any history line. The next push on any feature branch will trigger the build of a new merge that will be forced push again on `octopus`.\n\nOnce a feature branch is validated on your test environment, you can merge it on master.\n\n### Managing conflicts\nIf `git-octopus` fails, it will do a diagnostic sequence to figure out the conflict precisely. It can lead to two cases : \n\n* A conflict has been found\n\n\t1. Ask yourself if you could avoid that conflict. Rewriting the history is possible as long as you're alone working on the branch. \n\n\t2. Use [git-conflict](http://lesfurets.github.io/git-octopus/doc/git-conflict.html) to record a resolution and push it to origin. See the documentation for more details.\n\n\t3. Consider to remove one of the conflicting branches from the continuous integration (I.E. rename the branch so it won't get caught in the merge) and wait for the other to be merged in `master`. Then you'll be able to update and resolve the conflict.\n\n\t4. Rebase one branch on top of the other (depending on which one you want to ship first). This has to be the last resort because you'll loose branches independency.\n\n* No conflict found\n\n\t1. Someone else might breaks the merge, look at previous octopus job executions.\n\n\t2. You felt in a complex case. There are ongoing works to prevent that from happening but for the moment this might happen. Don't hesitate to open an issue !\n\n## Community\n\nWe have a [Google Group](https://groups.google.com/forum/#!forum/git-octopus), feel free to come and discuss with us. You can also send an email to git-octopus@googlegroups.com.\n\n[![Analytics](https://ga-beacon.appspot.com/UA-79856083-1/README.md?pixel\u0026useReferrer)](https://github.com/igrigorik/ga-beacon)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flesfurets%2Fgit-octopus","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flesfurets%2Fgit-octopus","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flesfurets%2Fgit-octopus/lists"}