Archive for May, 2008

I love you, INDEX

Okay, there wasn’t a blog entry on git for quite a while, but well, here it is. This time about the incredible INDEX mechanism and git add -i. (more…)

gc-utils v0.2.0 released

A lot has changed since the latest announcement on the blog. We brought up the major release v0.1.0 that brings gc-utils into production status. Since 0.1.0 gc-utils now uses an own remote branch to pull things into before rebasing the CVS changes on top of the master branch. Additionally we cleaned up some smaller notifications. v0.2.0 was pretty much done by Jan Günter, who restructured the sources and cleanup the makefile so that we get a much nicer generation of files. Additionally Ping Yin, who is currently working heavily on git and tools around git fixed a issue with cvsps that might occur in particular environments. Finally we prepared gc-utils to be able to detect a brighter range of git versions to verify if gc-utils can be used with those git versions.

Let’s do it the git way and just provide the diffstats between v0.4.0 and v0.2.0:

David Soria Parra (32):
Add a “Update…” message to
Check if the a .cvs directory is present.
Fix the check for the .cvs directory.
Aggregate duplicated code into on library file.
Add license header
Test to invoke gc-utils from subdirectories
Testcase for gc-commit
Import branches into refs/remotes/cvs/* by default
When running cvsclean, gc-commit didn’t return to the working directory
Check if the directory to import already exists.
Change required git version from 1.5.0 to 1.5.4
Tests: Test merge strategy option in gc-update
Tests: Display filename when a test fails
Tests: Silence cleanup script
gc-utils version 0.0.5beta1
Add UPDATE-NOTES containing informations about compatiblity breaks
Silence git-stash when gc-update is not in verbose mode
Pop stashed status always, not only when we rebase
Fix the check for the .git and .cvs directory
Cleanup manpages
Use die shortcut instead of echo >&2 && exit 127
Show a message that we run cvs update
Silence errors due to non integer inputs in our select
Simplify code
gc-utils version 0.1.0
Let install(1) create our directories
Change required git version from 1.5.4 to 1.5.3
Fix the check for git versions
Tests: Wait a second before recommiting a change
Merge branch ‘maint’
Merge branch ‘master’ into next
gc-utils version 0.2.0 the ‘yellow t-shirt’ release

Eduardo Cardoso (2):
Uses –no-pager to retrieve log messages.
Added flags to `cvs update’ to allow creation of directories and pruning of empty directories.

Jan Günter (7):
Added .gitignore file
manpage syntx correction
Removed the manpage numbers from gc-utils commands output
Update mandb after installing manpages
Suppress sed commands in Makefile output
Restructuring project files
Code cleanup

Ping Yin (1):
Sometimes “cvsps –cvs-direct” may not work, so use -gn to allow

.gitignore | 8 ++
ChangeLog | 107 ++++++++++++++++++++++
Makefile | 69 +++++———-
doc/.gitignore | 9 ++
doc/Makefile | 46 ++++++++++
doc/gc-commit.1 | 46 ++++++++++
doc/gc-import.1 | 63 +++++++++++++
doc/gc-multi-commit.1 | 29 ++++++
doc/gc-update.1 | 54 +++++++++++
gc-utils.1 => doc/gc-utils.1 | 26 +++—
gc-commit.1 | 45 ———
gc-import.1 | 56 ————
gc-multi-commit.1 | 29 —— | 182 ————————————–
gc-update.1 | 54 ———– | 158 ———————————
src/.gitignore | 9 ++
src/Makefile | 63 +++++++++++++ => src/ | 68 ++++———– => src/ | 84 +++++++———–
src/ | 147 ++++++++++++++++++++++++++++++
src/ | 44 +++++++++
src/ | 138 +++++++++++++++++++++++++++++ => src/ | 54 +++——–
tests/ | 29 ++++++
tests/ | 21 +++++
tests/ | 29 ++++++
tests/ | 4 +-
tests/ | 17 +++-
tests/ | 2 +-
tests/ | 4 +-
32 files changed, 968 insertions(+), 736 deletions(-)
create mode 100644 .gitignore
create mode 100644 UPDATE-NOTES
create mode 100644 doc/.gitignore
create mode 100644 doc/Makefile
create mode 100644 doc/gc-commit.1
create mode 100644 doc/gc-import.1
create mode 100644 doc/gc-multi-commit.1
create mode 100644 doc/gc-update.1
rename gc-utils.1 => doc/gc-utils.1 (66%)
delete mode 100644 gc-commit.1
delete mode 100644 gc-import.1
delete mode 100644 gc-multi-commit.1
delete mode 100755
delete mode 100644 gc-update.1
delete mode 100644
create mode 100644 src/.gitignore
create mode 100644 src/Makefile
rename => src/ (57%)
rename => src/ (54%)
create mode 100644 src/
create mode 100644 src/
create mode 100644 src/
rename => src/ (53%)
create mode 100644 tests/
create mode 100644 tests/
create mode 100644 tests/

gc-utils is a small set of bash scripts that wrap git-cvsimport(1) to make importing cvs repositories and exporting commits back into cvs easier. It is licensed under the terms of the MIT/2-Clause BSD license. gc-utils is available at

ZSH and git branches

I recently stumbled over a nice code snippet for my .zshrc which shows the current branch in a git repository on the right prompt:

git_prompt_info() {
ref=$(git-symbolic-ref HEAD 2> /dev/null) || echo “”
echo ” (${ref#refs/heads/})”

setopt prompt_subst