tags:

views:

67

answers:

1

I'm using github to store my PowerShell profile. I found posh-vcs that I'd like to use on top of my actual implementation. I'd like to be able to merge changes from posh-vcs to my current environment.

What would be the best way to handle this? Just have one repository for my files, and in another folder have the posh-vcs? Or is this an appropriate use of the Fork? i.e., fork the project and add my own files, merging from the parent project when appropriate?

+2  A: 

If you have a similar structure between the two repositories, you can try a grafts technique to:

  • fork his project
  • import your history into this forked repo

The fork is only interesting if you want to contribute back to that external repo.
If not, you can simply clone the external repo and import your history through the grafts file, changing your repo (without any link with the post-vcs repo)


Other options involves:

  • considering the external repo as a subtree of your repo (subtree merge strategy)
  • considering the external repo as a submodule of your repo( quite handy if you need to push/pull from the post-vcs repo, while managing your own repo)

See those two options in the question on repo tranfers, with this answer for more on submodules.

VonC
Thanks for the reply. I'll have to try that out. That's kind of what I figured wrt Forking. But I recall reading somewhere that you could fork even if you have no intention of merging back... But, I think your method above makes more sense...
Bryce Fischer