0

I am having hard time devising a workflow for github now that we have swtiched over from clearcase ucm to github.

In clearcase ucm, I just had a development stream and an integration stream. all developers check in under dev stream which finally gets merged to int stream and baselined.

How can the same thing be done in github?

user2636464
  • 685
  • 7
  • 17

1 Answers1

1

A stream in ClearCase is a akin to a Git branch in order for multiple developers to collaborate to a common development effort (by delivering/rebasing to that stream)

Since Git is a distributed VCS, you can achieve the same collaboration by:

  • making local commit to a branch (typically dev for development)
  • pushing those commits to a common remote repo

If others have already pushed their own commits (like a deliver), you would git pull --rebase first (a bit like a rebase), resolve any conflict, and push back.

A true Git workflow would involve feature branches, that you would then combine and merge to a dev branch, then an integration branch, then, for release, master. Like gitworkflow.

The remote repo can be managed by a Git repository hosting service, like GitHub, BitBucket or Gitlab.

VonC
  • 1,262,500
  • 529
  • 4,410
  • 5,250
  • So I can achieve the same collaboration by: Clone the remote branch and commit locally pushing those commits to a same branch in remote ? Does this make sense? – user2636464 Apr 18 '19 at 08:56
  • @user2636464 Actually, you clone every branch of a repo, then checkout the dev one, work on it and push back: a clone is of a full repo, full history of all branches. – VonC Apr 18 '19 at 08:56
  • I tried using --single-branch option to clone only the required one and not all branches. probably going forward I would like to have a better workflow once we are all trained in. thanks for the git workflow link. – user2636464 Apr 18 '19 at 08:58
  • @user2636464 Right! I mentioned the `--single-branch` option 7 years ago (https://stackoverflow.com/a/9920956/6309). I should have remembered! – VonC Apr 18 '19 at 09:01
  • There are some gotchas, especially if the project uses GIT submodules, as that doesn't look as baked as the proprietary SCM systems. I found MS's GIT Virtial File System to be an interesting read because they got hit hard by "what happens when you have a HUGE git repo?" Can you imagine the "fun" of managing a 300GB codebase in ANY SCM tool, much less one that puts a complete copy of the repo on every user workstation? – Brian Cowan Apr 18 '19 at 18:05
  • @BrianCowan Yes, I mention what is now called VFS for Git here: https://stackoverflow.com/a/52549508/6309. ClearCase dynamic views are coming to Git! – VonC Apr 18 '19 at 23:11
  • @BrianCowan I have not used git submodules due to its complexities. Either I have one repo if its small or multiple repos if its big. – user2636464 Apr 23 '19 at 14:08