- State "TODO" [2008-08-28 Thu 05:06]
*** TODO [[http://book.git-scm.com/][Git Community Book]] Open source wiki/howto website
+ :PROPERTIES:
+ :CUSTOM_ID: git-book
+ :END:
- State "TODO" [2008-08-28 Thu 05:06]
** Interface with SVN
Don't forget to =chmod 744= both scripts to make them executible.
Also note that these scripts are run from the base repo directory,
which is why I had to include the relative path to
-pre-commit-make-check, and didn't need =cd ../../= in the check
+=pre-commit-make-check=, and didn't need =cd ../../= in the check
script.
*** DONE [[http://changelog.complete.org/posts/586-Rebase-Considered-Harmful.html][Rebase Considered Harmful]]
* Case studies
-** Gitting chem_web, my first git project
+** Gitting =chem_web=, my first git project
*** Repository creation and setup
-From the [[Git Community Book]].
+From the [[#git-book][Git Community Book]].
*** Install
: $ git checkout master
: $ git merge dev
-You may have to deal with a [[*conflicting merge]].
+You may have to deal with a [[#conflicting-merge][conflicting merge]].
*** Delete a branch
From the [[http://book.git-scm.com/3_basic_branching_and_merging.html][Git Community Book]].
: $ apt-get install git-core git-svn gitk
*** Repository migration from svn
+ :PROPERTIES:
+ :CUSTOM_ID: svn-migration
+ :END:
+
Following [[http://github.com/maddox][Jon Maddox]] at the [[http://www.simplisticcomplexity.com/2008/03/05/cleanly-migrate-your-subversion-repository-to-a-git-repository/][Simplistic Complexity blog]].
**** Create the decoy directory
avoid having all your =git status= calls swamped with untracked files,
Just add the filenames (globbing allowed) to =.gitignore=.
-**** [[Push hooks]]
+**** Push hooks
TODO
*** Making your repository public/Publishing your repository
*** Repository creation and setup
-This is quite similar to [[*Repository migration from svn]]
+This is quite similar to [[#svn-migration][svn migration]].
**** Create the decoy directory
The login line may not be necessary for other CVS projects.
Arguments to git-cvsimport:
- |--------+---------------------------------------------------------------------|
- | Option | Meaning |
- |--------+---------------------------------------------------------------------|
- | -p x | Pass =-x= to =cvsps=, which ignores any =~/.cvsps/cvsps.cache= file |
- |--------+---------------------------------------------------------------------|
- | -* -v | Verbose |
- |--------+---------------------------------------------------------------------|
- | -d ... | From http://www.comedi.org/download.html |
- |--------+---------------------------------------------------------------------|
+ |----------+---------------------------------------------------------------------|
+ | Option | Meaning |
+ |----------+---------------------------------------------------------------------|
+ | =-p x= | Pass =-x= to =cvsps=, which ignores any =~/.cvsps/cvsps.cache= file |
+ |----------+---------------------------------------------------------------------|
+ | =-v= | Verbose |
+ |----------+---------------------------------------------------------------------|
+ | =-d ...= | From http://www.comedi.org/download.html |
+ |----------+---------------------------------------------------------------------|
**** Create the clean directory
: $ cd ../comedi
: $ git pull
-You may have to deal with a [[*conflicting merge]].
+You may have to deal with a [[#conflicting-merge][conflicting merge]].
*** Create a patch against the cvs source
This is a nice way of grouping associated projects. The submodules
are included as stand-alone repositories, and the super-project has
pointers picking out a particular revision of each submoduel. See the
-related [[*Git subtrees]] for an alternate approach.
+related [[#git-subtrees][Git subtrees]] for an alternate approach.
*** References
[[http://git.or.cz/gitwiki/GitSubmoduleTutorial][Git Wiki]]
: d266b9873ad50488163457f025db7cdd9683d88b HEAD@{2}: checkout: moving to d266b9873ad50488163457f025db7
** Git subtrees, merging an entire repository into a subdirectory of your repository
+ :PROPERTIES:
+ :CUSTOM_ID: git-subtrees
+ :END:
*** Setup
From [[http://www.kernel.org/pub/software/scm/git/docs/howto/using-merge-subtree.html][kernel.org: merge-subtree]]
fixed the problem for me.
** Conflicting merge
+ :PROPERTIES:
+ :CUSTOM_ID: conflicting-merge
+ :END:
=git pull= or =git merge= aborts with =merge-failed= or some such.
This leaves your checked out branch in a state where
: $ git diff
-shows the merge difficulties. You can either [[*abort the merge]], or
-[[*merge by hand]].
+shows the merge difficulties. You can either [[#abort-merge][abort the merge]], or
+[[#hand-merge][merge by hand]].
*** Abort the merge
+ :PROPERTIES:
+ :CUSTOM_ID: abort-merge
+ :END:
: $ git reset --hard HEAD
*** Merge by hand
+ :PROPERTIES:
+ :CUSTOM_ID: hand-merge
+ :END:
Edit the marked packages as you see fit. Then let Git know you've
accepted your changes with either