[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Git vs SVN

2008/11/10 Barry deFreese <bdefreese@verizon.net>:
> Eddy Petrișor wrote:
>> <snip>
>>> Understood and thanks.  I guess what I'm really struggling with is that I
>>> just don't know git well enough yet to make an informed decision about
>>> it's
>>> usage.
>>> I need a mentor! :)
>> What would you like to know? Maybe we should continue this
>> conversation on IRC. I am confident that you'll find KiBi, myself and
>> Rhonda good enough to explain/tutor your git usage.
>> Still, I recommend you try to follow one of the multiple git tutorials
>> out there and try to stick with git for a week or so. If properly
>> done, I'm sure you'll fall in love.
> Eddy,
> I have already imported one into Git (gtkatlantic) so I've used the wiki and
> know enough to be dangerous.


> But, for example, some of the ones I'm looking
> at like xbl (one of Joey Hess's packages)  is already in his git repo so I
> pulled that.

(I looked at that repo.)

> But can I "easily" add the pristine-tar (or even upstream)
> crap somehow and then get it into ours?

(Ah, I see, Joey hasn't used an upstream branch, nor a pristine-tar branch.)

It's quite easy, and there are multiple ways of doing it.

The easiest way is to create a new repo, import upstream tarball, add
joey's as a remote and merge the two branches to obtain the new master

In detail:
- create a new git repo and import the latest upstream version (or the
last one that joey's repo holds)
- make a new branch called "upstream"
- delete the master branch
- while on the upstream branch, use pristine-tar commit to store the
meta-data about the tarball you just imported
- delete the master branch (you'll use joey's as master)
- add joey's repo as remote and fetch everything
- checkout joey's master as your new local master branch
- merge the upstream branch, making sure the master branch contents
wins in the merge

Push the upstream, pristine-tar and master branches to alioth and
people can already clone;
Locally make another clone from alioth to make sure alioth will be
your default remote and remove your intermediate repo which knew about
joey's repo.

Another more difficult (uses an advanced feature) way would be to
create in a repo clone of joey's and create one detached branch called
upstream, use pristine-tar commit, merge upstream with master, then
push to alioth, make a clone from alioth, remove your initial clone.

> I can even get git-buildpackage to
> run on it.

I didn't understood if this was a question or an affirmative sentence.

"Imagination is more important than knowledge" A.Einstein

Reply to: