aboutsummaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAge
* More staticJunio C Hamano2007-06-13
| | | | | | There still are quite a few symbols that ought to be static. Signed-off-by: Junio C Hamano <gitster@pobox.com>
* -Wold-style-definition fixJunio C Hamano2007-06-13
| | | | Signed-off-by: Junio C Hamano <gitster@pobox.com>
* Makefile: allow generating git.o for debugging purposesJunio C Hamano2007-06-13
| | | | Signed-off-by: Junio C Hamano <gitster@pobox.com>
* Makefile: common-cmds.h depends on generate-cmdlist.sh scriptJunio C Hamano2007-06-13
| | | | Signed-off-by: Junio C Hamano <gitster@pobox.com>
* Merge branch 'jc/blame' (early part)Junio C Hamano2007-06-13
|\ | | | | | | | | | | * 'jc/blame' (early part): git-blame -w: ignore whitespace git-blame: do not indent with spaces.
| * git-blame -w: ignore whitespaceJunio C Hamano2007-06-09
| | | | | | | | | | | | | | | | | | | | | | When refactoring code to split one iteration of a too deeply nested loop into a separate function, it inevitably makes the indentation levels shallower (that's the sole point of such a refactoring). With "git blame -w", you can ignore such re-indentation and pass blame for such moved lines to the parent. Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * git-blame: do not indent with spaces.Junio C Hamano2007-06-09
| | | | | | | | Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | refactor dir_add_nameJeff King2007-06-12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is in preparation for keeping two entry lists in the dir object. This patch adds and uses the ALLOC_GROW() macro, which implements the commonly used idiom of growing a dynamic array using the alloc_nr function (not just in dir.c, but everywhere). We also move creation of a dir_entry to dir_entry_new. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | git-remote show: Also shorten non-fast-forward refs in the 'push' listingJohannes Sixt2007-06-12
| | | | | | | | | | | | | | | | | | | | 'git-remote show remote-name' lists the refs that are pushed to the remote by showing the 'Push' line from the config file. But before showing it, it shortened 'refs/heads/here:refs/heads/there' to 'here:there'. However, if the Push line is prefixed with a plus, the ref was not shortened. Signed-off-by: Johannes Sixt <johannes.sixt@telecom.at> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | gitweb: change filename/directory name of snapshotsMatthias Lederhofer2007-06-12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | /.git or .git is removed from the project name and the basename of the remaining path is used as the beginning of the filename and as the directory in the archive. The regexp will actually not strip off /.git or .git if there wouldn't be anything left after removing it. Currently the full project name is used as directory in the archive and the basename is used as filename. For example a repository named foo/bar/.git will have a archive named .git-<version>.* and extract to foo/bar/.git. With this patch the file is named bar-<version>.* and extracts to bar. Signed-off-by: Matthias Lederhofer <matled@gmx.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | Don't dereference a strdup-returned NULLJim Meyering2007-06-12
| | | | | | | | | | | | | | | | There are only a dozen or so uses of strdup in all of git. Of those, most seem ok, but this one isn't: Signed-off-by: Jim Meyering <jim@meyering.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | Merge branch 'maint'Junio C Hamano2007-06-12
|\ \ | | | | | | | | | * maint:
| * \ Merge branch 'ar/clone' into maintJunio C Hamano2007-06-12
| |\ \ | | | | | | | | | | | | | | | | * ar/clone: Fix clone to setup the origin if its name ends with .git
| * \ \ Merge branch 'sv/objfixes' into maintJunio C Hamano2007-06-12
| |\ \ \ | | | | | | | | | | | | | | | | | | | | * sv/objfixes: Don't assume tree entries that are not dirs are blobs
* | \ \ \ Merge branch 'aw/cvs'Junio C Hamano2007-06-12
|\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * aw/cvs: cvsimport: add <remote>/HEAD reference in separate remotes more cvsimport: update documentation to include separate remotes option cvsimport: add support for new style remote layout
| * | | | | cvsimport: add <remote>/HEAD reference in separate remotes moreAndy Whitcroft2007-06-06
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When in separate remote mode (via -r <remote>) we can now use the name HEAD for the CVS HEAD. In keeping with git-clone remotes/<remote>/HEAD is creates as a symbolic ref to the user specified name for the HEAD which defaults to master. Signed-off-by: Andy Whitcroft <apw@shadowen.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | | | cvsimport: update documentation to include separate remotes optionAndy Whitcroft2007-06-06
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Document the cvsimport -r <remote> option which switches cvsimport to using a separate remote for tracking branches. Signed-off-by: Andy Whitcroft <apw@shadowen.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | | | cvsimport: add support for new style remote layoutAndy Whitcroft2007-06-06
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | cvsimport creates any branches found in the remote CVS repository in the refs/heads namespace. This makes sense for a repository conversion. When using git as a sane interface to a remote CVS repository, that repository may well remain as the 'master' respository. In this model it makes sense to import the CVS repository into the refs/remotes namespace. Add a new option '-r <remote>' to set the remote name for this import. When this option is specified branches are named refs/remotes/<remote>/branch, with HEAD named as master matching git-clone separate remotes layout. Without branches are placed ion refs/heads, with HEAD named origin as before. Signed-off-by: Andy Whitcroft <apw@shadowen.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | | | Merge branch 'ep/cvstag'Junio C Hamano2007-06-12
|\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | * ep/cvstag: Use git-tag in git-cvsimport
| * | | | | | Use git-tag in git-cvsimportElvis Pranskevichus2007-06-06
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently git-cvsimport tries to create tag objects directly via git-mktag in a very broken way, e.g the stuff it writes into the tagger field of the tag object doesn't really resemble the GIT_COMMITTER_IDENT. This makes gitweb and possibly other tools that try to interpret tag objects to be confused about tag date and authorship. Fix this by calling git-tag instead. This also has a nice side effect of not creating the tag object but only the lightweight tag as that's the only thing CVS has anyways. Signed-off-by: Elvis Pranskevichus <el@prans.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | | | | Teach diff to imply --find-copies-harder upon -C -CJohannes Schindelin2007-06-12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Earlier, a second "-C" on the command line had no effect. But "--find-copies-harder" is so long to type, let's make doubled -C enable that option. It is in line with how "git blame" handles such doubled options to mean "work harder". Signed-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | | | | Remove trailing slash from $(template_dir).Johannes Sixt2007-06-12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | All the other directory location variables do not have the trailing slash. Signed-off-by: Johannes Sixt <johannes.sixt@telecom.at> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | | | | Avoid double-slash in path names that depend on $(sharedir).Johannes Sixt2007-06-12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Recent git-gui has the ability to determine the location of its library files relative to the --exec-dir. Its Makefile enables this capability depending on the install paths that are specified. However, without this fix there is an extra slash in a path specification, so that the Makefile does not recognize the equivalence of two paths that it compares. A side-effect is that all "standard" builds (which do not set $(sharedir) explicitly) now exploit above mentioned gut-gui feature. Another side-effect is that an ugly compiled-in double-slash in $(template_dir) is avoided. Signed-off-by: Johannes Sixt <johannes.sixt@telecom.at> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | | | | Merge branch 'lh/submodule'Junio C Hamano2007-06-12
|\ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * lh/submodule: git-submodule: clone during update, not during init git-submodule: move cloning into a separate function
| * | | | | | | git-submodule: clone during update, not during initLars Hjemli2007-06-06
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This teaches 'git-submodule init' to register submodule paths and urls in .git/config instead of actually cloning them. The cloning is now handled as part of 'git-submodule update'. With this change it is possible to specify preferred/alternate urls for the submodules in .git/config before the submodules are cloned. Signed-off-by: Lars Hjemli <hjemli@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | | | | | git-submodule: move cloning into a separate functionLars Hjemli2007-06-06
| | |/ / / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is just a simple refactoring of modules_init() with no change in functionality. Signed-off-by: Lars Hjemli <hjemli@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
* | | | | | | Merge branch 'maint'Junio C Hamano2007-06-12
|\ \ \ \ \ \ \ | | |_|/ / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | * maint: Unquote From line from patch before comparing with given from address. git-cherry: Document 'limit' command-line option
| * | | | | | Unquote From line from patch before comparing with given from address.Kristian Høgsberg2007-06-12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This makes --suppress-from actually work when you're unfortunate enough to have non-ASCII in your name. Also, if there's a match use the optionally RFC2047 quoted version from the email. Signed-off-by: Kristian Høgsberg <krh@redhat.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | | | | git-cherry: Document 'limit' command-line optionLuiz Fernando N. Capitulino2007-06-12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Luiz Fernando N. Capitulino <lcapitulino@mandriva.com.br> Signed-off-by: Junio C Hamano <gitster@pobox.com>
| * | | | | | Merge branch 'maint' of git://repo.or.cz/git-gui into maintJunio C Hamano2007-06-12
| |\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * 'maint' of git://repo.or.cz/git-gui: git-gui: Save geometry before the window layout is damaged git-gui: Give amend precedence to HEAD over MERGE_MSG git-gui: Include 'war on whitespace' fixes from git.git
* | \ \ \ \ \ \ Merge branch 'master' of git://repo.or.cz/git-guiJunio C Hamano2007-06-12
|\ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * 'master' of git://repo.or.cz/git-gui: git-gui: Save geometry before the window layout is damaged git-gui: Give amend precedence to HEAD over MERGE_MSG git-gui: Include 'war on whitespace' fixes from git.git
| * \ \ \ \ \ \ \ Merge branch 'maint'Shawn O. Pearce2007-06-11
| |\ \ \ \ \ \ \ \ | | | |/ / / / / / | | |/| | | | | | | | | | | | | | | | | | | | | | | | * maint: git-gui: Save geometry before the window layout is damaged git-gui: Give amend precedence to HEAD over MERGE_MSG
| | * | | | | | | git-gui: Save geometry before the window layout is damagedShawn O. Pearce2007-06-11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Because Tk does not assure us the order that it will process children in before it destroys the main toplevel we cannot safely save our geometry data during a "bind . <Destroy>" event binding. The geometry may have already changed as a result of a one or more children being removed from the layout. This was pointed out in gitk by Mark Levedahl, and patched over there by commit b6047c5a8166a71e01c6b63ebbb67c6894d95114. So we now also use "wm protocol . WM_DELETE_WINDOW" to detect when the window is closed by the user, and forward that close event to our main do_quit routine. Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
| | * | | | | | | git-gui: Give amend precedence to HEAD over MERGE_MSGShawn O. Pearce2007-06-11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Apparently git-commit.sh (the command line commit user interface in core Git) always gives precedence to the prior commit's message if `commit --amend` is used and a $GIT_DIR/MERGE_MSG file also exists. We actually were doing the same here in git-gui, but the amended message got lost if $GIT_DIR/MERGE_MSG already existed because we started a rescan immediately after loading the prior commit's body into the edit buffer. When that happened the rescan found MERGE_MSG existed and replaced the commit message buffer with the contents of that file. This meant the user never saw us pick up the commit message of the prior commit we are about to replace. Johannes Sixt <J.Sixt@eudaptics.com> found this bug in git-gui by running `git cherry-pick -n $someid` and then trying to amend the prior commit in git-gui, thus combining the contents of $someid with the contents of HEAD, and reusing the commit message of HEAD, not $someid. With the recent changes to make cherry-pick use the $GIT_DIR/MERGE_MSG file Johannes saw git-gui pick up the message of $someid, not HEAD. Now we always use HEAD if we are amending. Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
| * | | | | | | | Merge branch 'maint'Shawn O. Pearce2007-06-11
| |\ \ \ \ \ \ \ \ | | |/ / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | * maint: git-gui: Include 'war on whitespace' fixes from git.git
| | * | | | | | | git-gui: Include 'war on whitespace' fixes from git.gitShawn O. Pearce2007-06-11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Earlier git.git applied a large "war on whitespace" patch that was created using 'apply --whitespace=strip'. Unfortunately a few of git-gui's own files got caught in the mix and were also cleaned up. That was a6080a0a44d5ead84db3dabbbc80e82df838533d. This patch is needed in git-gui.git to reapply those exact same changes here, otherwise our version generator script is unable to obtain our version number from git-describe when we are hosted in the git.git repository. Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* | | | | | | | | Merge branch 'master' of git://repo.or.cz/git-guiJunio C Hamano2007-06-11
|\ \ \ \ \ \ \ \ \ | |/ / / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * 'master' of git://repo.or.cz/git-gui: git-gui: Internalize symbolic-ref HEAD reading logic git-gui: Expose the merge.diffstat configuration option git-gui: Allow users to delete remote branches git-gui: Allow users to rename branches through 'branch -m' git-gui: Disable tearoff menus on Windows, Mac OS X git-gui: Provide fatal error if library is unavailable git-gui: Enable verbose Tcl loading earlier git-gui: Show the git-gui library path in 'About git-gui' git-gui: GUI support for running 'git remote prune <name>' git gui 0.8.0
| * | | | | | | | Merge branch 'maint'Shawn O. Pearce2007-06-11
| |\ \ \ \ \ \ \ \ | | |/ / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * maint: (38 commits) git-gui: Changed blame header bar background to match main window git-gui: Favor the original annotations over the recent ones git-gui: Improve our labeling of blame annotation types git-gui: Use three colors for the blame viewer background git-gui: Jump to original line in blame viewer git-gui: Display both commits in our tooltips git-gui: Run blame twice on the same file and display both outputs git-gui: Display the "Loading annotation..." message in italic git-gui: Rename fields in blame viewer to better descriptions git-gui: Label the uncommitted blame history entry git-gui: Switch internal blame structure to Tcl lists git-gui: Cleanup redundant column management in blame viewer git-gui: Better document our blame variables git-gui: Remove unused commit_list from blame viewer git-gui: Automatically expand the line number column as needed git-gui: Make the line number column slightly wider in blame git-gui: Use lighter colors in blame view git-gui: Remove unnecessary space between columns in blame viewer git-gui: Remove the loaded column from the blame viewer git-gui: Clip the commit summaries in the blame history menu ...
| * | | | | | | | Merge branch 'maint'Shawn O. Pearce2007-06-06
| |\ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * maint: New selection indication and softer colors
| * \ \ \ \ \ \ \ \ Merge branch 'maint'Shawn O. Pearce2007-06-02
| |\ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * maint: Revert "Make the installation target of git-gui a little less chatty" git-gui: Verify Tcl/Tk is new enough for our needs git-gui: Attach font_ui to all spinbox widgets
| * \ \ \ \ \ \ \ \ \ Merge branch 'maint'Shawn O. Pearce2007-06-01
| |\ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * maint: git-gui: Don't quit when we destroy a child widget Make the installation target of git-gui a little less chatty
| * | | | | | | | | | | git-gui: Internalize symbolic-ref HEAD reading logicShawn O. Pearce2007-05-31
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | To improve performance on fork+exec impoverished systems (such as Windows) we want to avoid running git-symbolic-ref on every rescan if we can do so. A quick way to implement such an avoidance is to just read the HEAD ref ourselves; we'll either see it as a symref (starts with "ref: ") or we'll see it as a detached head (40 hex digits). In either case we can treat that as our current branch. Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
| * | | | | | | | | | | Merge branch 'maint'Shawn O. Pearce2007-05-31
| |\ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * maint: git-gui: Allow as few as 0 lines of diff context
| * \ \ \ \ \ \ \ \ \ \ \ Merge branch 'maint'Shawn O. Pearce2007-05-30
| |\ \ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * maint: git-gui: Allow creating a branch when none exists
| * | | | | | | | | | | | | git-gui: Expose the merge.diffstat configuration optionShawn O. Pearce2007-05-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Recently git-merge learned to avoid generating the diffstat after a merge by reading the merge.diffstat configuration option. By default this option is assumed to be true, as that is the old behavior. However we can force it to false by setting it as a standard boolean option. Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
| * | | | | | | | | | | | | git-gui: Allow users to delete remote branchesShawn O. Pearce2007-05-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Git has supported remote branch deletion for quite some time, but I've just never gotten around to supporting it in git-gui. Some workflows have users push short-term branches to some remote Git repository, then delete them a few days/weeks later when that topic has been fully merged into the main trunk. Typically in that style of workflow the user will want to remove the branches they created. We now offer a "Delete..." option in the Push menu, right below the generic "Push..." option. When the user opens our generic delete dialog they can select a preconfigured remote, or enter a random URL. We run `git ls-remote $url` to obtain the list of branches and tags known there, and offer this list in a listbox for the user to select one or more from. Like our local branch delete dialog we offer the user a way to filter their selected branch list down to only those branches that have been merged into another branch. This is a very common operation as the user will likely want to select a range of topic branches, but only delete them if they have been merged into some sort of common trunk. Unfortunately our remote merge base detection is not nearly as strict as the local branch version. We only offer remote heads as the test commit (not any local ones) and we require that all necessary commits to successfully run git-merge-base are available locally. If one or more is missing we suggest that the user run a fetch first. Since the Git remote protocol doesn't let us specify what the tested commit was when we evaluated our decision to execute the remote delete there is a race condition here. The user could do a merge test against the trunk, determine a topic branch was fully merged, but before they can start pushing the delete request another user could fast-forward the remote topic branch to a new commit that is not merged into the trunk. The delete will arrive after, and remove the topic, even though it was not fully merged. Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
| * | | | | | | | | | | | | git-gui: Allow users to rename branches through 'branch -m'Shawn O. Pearce2007-05-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Git's native command line interface has had branch renaming support for quite a while, through the -m/-M options to the git-branch command line tool. This is an extremely useful feature as users may decide that the name of their current branch is not an adequate description, or was just entered incorrectly when it was created. Even though most people would consider git-branch to be a Porcelain tool I'm using it here in git-gui as it is the only code that implements the rather complex set of logic needed to successfully rename a branch in Git. Currently that is along the lines of: *) Backup the ref *) Backup the reflog *) Delete the old ref *) Create the new ref *) Move the backed up reflog to the new ref *) Record the rename event in the reflog *) If the current branch was renamed, update HEAD *) If HEAD changed, record the rename event in the HEAD reflog *) Rename the [branch "$name"] section in the config file Since that is some rather ugly set of functionality to implement and get right, and some of it isn't easily accessible through the raw plumbing layer I'm just cheating by relying on the Porcelain. Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
| * | | | | | | | | | | | | git-gui: Disable tearoff menus on Windows, Mac OS XShawn O. Pearce2007-05-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The Windows and Mac OS X platforms do not generally use the tearoff menu feature found on traditional X11 based systems. On Windows the Tk engine does support the feature, but it really is out of place and just confuses people who aren't used to working on a UNIX system. On Mac OS X its not supported for the root menu bar and its submenus, as it doesn't fit into the overall platform UI model. Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
| * | | | | | | | | | | | | git-gui: Provide fatal error if library is unavailableShawn O. Pearce2007-05-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If we cannot locate our git-gui library directory, or we find it but the tclIndex file is not present there (or it is present but is not something we are allowed to read) the user cannot use the application. Rather than silently ignoring the errors related to the tclIndex file being unavailable we report them up front and display to the user why we cannot start. Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
| * | | | | | | | | | | | | git-gui: Enable verbose Tcl loading earlierShawn O. Pearce2007-05-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When we are using our "non-optimized" tclIndex format (which is just a list of filenames, in the order necessary for source'ing) we are doing all of our loading before we even tested to see if GITGUI_VERBOSE was set in the environment. This meant we never showed the files as we sourced them into the environment. Now we setup our overloaded auto_load and source scripts before we attempt to define our library path, or source the scripts that it mentions. This way GITGUI_VERBOSE is always honored if set. Signed-off-by: Shawn O. Pearce <spearce@spearce.org>