aboutsummaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAge
* git-gui: Clarify the Remote -> Delete... actionPetr Baudis2008-09-30
| | | | | | | | | | Currently, it was not really clear what all does this perform. We rename "Delete..." to "Delete Branch..." (since this does not delete the remote as a whole) and relabel the window from "Delete Remote Branch" to "Delete Branch Remotely" (since the action also involves pushing the delete out). Signed-off-by: Petr Baudis <petr.baudis@novartis.com> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* git-gui: Remove space from the end of aspell's reply before processingJohannes Sixt2008-09-30
| | | | | | | | | | | When git gui processes a reply from aspell it explicitly ignores an empty line. The Windows version of aspell, however, terminates lines with CRLF, but TCL's 'gets' does not remove CR, hence, a "visibly" empty line was not actually recognized as empty. With this change we explicitly trim off whitespace before the line is further processed. Signed-off-by: Johannes Sixt <johannes.sixt@telecom.at> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* git-gui: Make Ctrl-T safe to use for conflicting files.Alexander Gavrilov2008-09-30
| | | | | | | | | | | | | A previous patch added a check for conflict markers, which is done when the file is about to be staged due to a click on the icon. However, pressing Ctrl-T still immediately stages the file without confirmation. This patch fixes it. The check requires a loaded diff, so staging multiple files at once won't work if they are unmerged. Signed-off-by: Alexander Gavrilov <angavrilov@gmail.com> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* git-gui: Do not automatically stage file after merge tool finishesJohannes Sixt2008-09-30
| | | | | | | | | | | | | If a merge tool was invoked on a conflicted file and the tool completed, then the conflicted file was staged automatically. However, the fact that the user closed the merge tool cannot be understood as the unequivocal sign that the conflict was completely resolved. For example, the user could have decided to postpone the resolution of the conflict, or could have accidentally closed the tool. We better leave the file unstaged and let the user stage it explicitly. Signed-off-by: Johannes Sixt <johannes.sixt@telecom.at> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* git-gui: Show/hide "Sign Off" based on nocommitmsg optionShawn O. Pearce2008-09-26
| | | | | | | | | If citool --nocommit is invoked we hide the Sign Off features, as the commit message area is not editable. But we really want the selection tied to the message area's editing ability. Suggested-by: Alexander Gavrilov <angavrilov@gmail.com> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* Merge branch 'maint'Shawn O. Pearce2008-09-26
|\
| * git-gui: Help identify aspell version on Windows tooGustaf Hendeby2008-09-26
| | | | | | | | | | | | | | | | | | | | On windows, git gui fails to correctly extract the aspell version (experienced with aspell version 0.50.3) due to scilent white space at the end of the version string. Trim the obtained version string to work around this. Signed-off-by: Gustaf Hendeby <hendeby@isy.liu.se> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* | git-gui: Reenable staging unmerged files by clicking the icon.Alexander Gavrilov2008-09-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This restores functionality of the file icon for unmerged files. Safety is enforced by loading the diff and checking for lines that look like conflict markers. If such lines are found, or the conflict involves deletion and/or symlinks, a confirmation dialog is presented. Otherwise, the icon immediately stages the working copy version of the file. Includes a revert of 2fe5b2ee42897a3acc78e5ddaace3775eb2713ca (Restore ability to Stage Working Copy for conflicts) Signed-off-by: Alexander Gavrilov <angavrilov@gmail.com> Tested-by: Johannes Sixt <johannes.sixt@telecom.at> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* | git-gui: Support the encoding menu in gui blame.Alexander Gavrilov2008-09-24
| | | | | | | | | | | | | | | | | | Allow dynamically changing the encoding from the blame viewer as well. Signed-off-by: Alexander Gavrilov <angavrilov@gmail.com> Tested-by: Johannes Sixt <johannes.sixt@telecom.at> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* | git-gui: Optimize encoding name resolution using a lookup table.Alexander Gavrilov2008-09-24
| | | | | | | | | | | | | | | | | | | | Encoding menu construction does almost a hundred of encoding resolutions, which with the old implementation led to a small but noticeable delay. Signed-off-by: Alexander Gavrilov <angavrilov@gmail.com> Tested-by: Johannes Sixt <johannes.sixt@telecom.at> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* | git-gui: Allow forcing display encoding for diffs using a submenu.Alexander Gavrilov2008-09-24
| | | | | | | | | | | | | | | | | | | | | | | | | | Add a submenu to allow dynamically changing the encoding to use for diffs. Encoding settings are remembered while git-gui runs. The rules are: 1) Encoding set for a specific file overrides gitattributes. 2) Last explicitly set value of the encoding overrides gui.encoding Signed-off-by: Alexander Gavrilov <angavrilov@gmail.com> Tested-by: Johannes Sixt <johannes.sixt@telecom.at> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* | git-gui: Add a menu of available encodings.Alexander Gavrilov2008-09-24
| | | | | | | | | | | | | | | | | | | | | | To make encoding selection easier, add a menu that lists available encodings to the Options window. Menu structure is borrowed from Firefox. Signed-off-by: Alexander Gavrilov <angavrilov@gmail.com> Tested-by: Johannes Sixt <johannes.sixt@telecom.at> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* | git-gui: Cleanup handling of the default encoding.Alexander Gavrilov2008-09-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Make diffs and blame default to the system (locale) encoding instead of hard-coding UTF-8. - Add a gui.encoding option to allow overriding it. - gitattributes still have the final word. The rationale for this is Windows support: 1) Windows people are accustomed to using legacy encodings for text files. For many of them defaulting to utf-8 will be counter-intuitive. 2) Windows doesn't support utf-8 locales, and switching the system encoding is a real pain. Thus the option. This patch also adds proper encoding conversion to Apply Hunk/Line. Signed-off-by: Alexander Gavrilov <angavrilov@gmail.com> Tested-by: Johannes Sixt <johannes.sixt@telecom.at> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* | git-gui: Assume `blame --incremental` output is in UTF-8Shawn O. Pearce2008-09-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Most commits have author name encoded in UTF-8, but the incremental blame output dumps raw bytes and doesn't give us the encoding header from the commit. Rather than fixing up tooltip data after we have viewed that particular commit in the blame viewer we can assume all names are in UTF-8. This is still going to cause problems when the author name is not encoded in UTF-8, but the only (efficient) way to solve that is to add an "encoding" header to the blame --incremental mode output, as otherwise we need to run `git cat-file commit $sha1` for each and every commit identified and that would be horribly expensive on any platform. Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* | git-gui: Use gitattribute "encoding" for file content displayShawn O. Pearce2008-09-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Most folks using git-gui on internationalized files have complained that it doesn't recognize UTF-8 correctly. In the past we have just ignored the problem and showed the file contents as binary/US-ASCII, which is wrong no matter how you look at it. This really should be a per-file attribute, managed by .gitattributes, so we now pull the "encoding" attribute data for the given path from the .gitattributes (if available) and use that, falling back to UTF-8 if the attributes are unavailable, git-check-attr is broken, or an encoding for this path not specified. We apply the encoding anytime we show file content, which currently is limited to only the diff viewer and the blame viewer. Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* | git-gui: Add support for calling out to the prepare-commit-msg hookJoshua Williams2008-09-24
| | | | | | | | | | Signed-off-by: Joshua Williams <joshua.williams@qlogic.com> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* | git-gui: Hide commit related UI during citool --nocommitShawn O. Pearce2008-09-24
| | | | | | | | | | | | | | | | | | If the user started git-gui as "git citool --nocommit" then they don't need the new commit / amend commit radio buttons, or the sign off button in the UI. Rather than use up space with options the user cannot activate they are simply not installed into the UI. Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* | git-gui: Add more integration options to citool.Alexander Gavrilov2008-09-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Make citool return nonzero exit code if it did not commit. - Add a mode where it does not actually commit and simply exits with zero code. Commit message is either disabled, or simply dumped to GITGUI_EDITMSG before exiting. - Add an option to immediately start it in amend mode. Rationale: 1) Use 'git citool --nocommit' instead of mergetool in scripts. 2) Use 'git citool --amend' to edit commits while rebasing. Signed-off-by: Alexander Gavrilov <angavrilov@gmail.com> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* | git-gui: Updated German translation.Christian Stimming2008-09-13
| | | | | | | | Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* | git-gui: I18n fix sentence parts into full sentences for translation again.Christian Stimming2008-09-12
| | | | | | | | | | | | | | | | | | For translations, it is almost always impossible to correctly translate parts of sentences in almost any other language. Hence, messages like this must be re-organized into full sentences. Signed-off-by: Christian Stimming <stimming@tuhh.de> Signed-off-by: Shawn O. Pearce <sop@google.com>
* | git-gui: Restore ability to Stage Working Copy for conflicts.Alexander Gavrilov2008-09-12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Tools like rerere leave files marked as conflicts in the index, while actually resolving them in the working copy. Also, some people like to use an external editor to resolve conflicts. This patch restores functionality previously removed in commit 617ceee653 by adding a new context menu item. It still ensures that the user does not stage conflicting files accidentally by clicking on the icon instead of the name. Signed-off-by: Alexander Gavrilov <angavrilov@gmail.com> Tested-by: Johannes Sixt <johannes.sixt@telecom.at> Signed-off-by: Shawn O. Pearce <sop@google.com>
* | git-gui: Fix Blame Parent & Context for working copy lines.Alexander Gavrilov2008-09-12
| | | | | | | | | | | | | | | | Make Blame Parent Commit and Show History Context work properly for lines blamed on the working copy. Signed-off-by: Alexander Gavrilov <angavrilov@gmail.com> Signed-off-by: Shawn O. Pearce <sop@google.com>
* | Merge branch 'maint'Shawn O. Pearce2008-09-04
|\ \ | |/ | | | | | | * maint: git-gui: Fix diff parsing for lines starting with "--" or "++"
| * git-gui: Fix diff parsing for lines starting with "--" or "++"Shawn O. Pearce2008-09-04
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Languages like Lua and SQL use "--" to mark a line as commented out. If this appears at column 0 and is part of the pre-image we may see "--- foo" in the diff, indicating that the line whose content is "-- foo" has been removed from the new version. git-gui was incorrectly parsing "--- foo" as the old file name in the file header, causing it to generate a bad patch file when the user tried to stage or unstage a hunk or the selected line. We need to keep track of where we are in the parsing so that we do not misread a deletion or addition record as part of the header. Reported-by: Alexander Gladysh <agladysh@gmail.com> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* | git-gui: Show special diffs for complex conflict cases.Alexander Gavrilov2008-09-04
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add special handling for displaying diffs of modified/deleted, and symlink/mode conflicts. Currently the display is completely unusable for deciding how to resolve the conflict. New display modes: 1) Deleted/Modified conflict: e.g. LOCAL: deleted REMOTE: [diff :1:$path :3:$path] 2) Conflict involving symlinks: LOCAL: [diff :1:$path :2:$path] REMOTE: [diff :1:$path :3:$path] In order to be able to display multiple diffs, this patch adds a queue of commands to call. Signed-off-by: Alexander Gavrilov <angavrilov@gmail.com> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* | git-gui: Make F5 reselect a diff, if an untracked file is selected.Alexander Gavrilov2008-09-04
| | | | | | | | | | | | | | | | | | | | | | | | | | | | If an untracked file is selected, F5 and other manual rescan synonyms would try to select a tracked file instead. Also, clicking on an icon in the unstaged changes list skips over untracked files, unless the file clicked is untracked itself. The objective is to make it easier to ignore untracked files showing up in the Unstaged Changes list, and ensure that no modifications to tracked objects are left unstaged. Signed-off-by: Alexander Gavrilov <angavrilov@gmail.com> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* | git-gui: Reimplement and enhance auto-selection of diffs.Alexander Gavrilov2008-09-04
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Generalize the next_diff system, and implement auto-reselection for merge tool resolution and reshow_diff. Also add auto-selection of diffs after rescan, if no diff is already selected. New auto-select rules: - Rescan auto-selects the first conflicting file, or if none a modified tracked file, if nothing was selected previously. - Resolving a conflict auto-selects the nearest conflicting file, or nothing if everything is resolved. - Staging the last remaining hunk auto-selects the nearest modified staged file. - Staging a file through its icon auto-selects the nearest file. Signed-off-by: Alexander Gavrilov <angavrilov@gmail.com> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* | git-gui: Support conflict states _U & UT.Alexander Gavrilov2008-09-04
| | | | | | | | | | | | | | | | | | | | | | | | Support _U (local deleted, remote modified) and UT (file type changed in conflict) modes. Note that 'file type changed' does not refer to changes in the executable bit, instead it denotes replacing a file with a link, or vice versa. Signed-off-by: Alexander Gavrilov <angavrilov@gmail.com> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* | git-gui: Support more merge tools.Alexander Gavrilov2008-09-04
| | | | | | | | | | | | | | | | | | | | | | Add native support for Araxis Merge, WinMerge and Perforce merge. Custom merge tools are not implemented by mergetool.tcl; besides, native support allows constructing the command lines in a more intelligent way. Signed-off-by: Alexander Gavrilov <angavrilov@gmail.com> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* | git-gui: Don't allow staging files with conflicts.Alexander Gavrilov2008-09-04
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Prevent staging files with conflict markers by clicking on the icon in the 'Unstaged Changes' list. Instead, pretend that the user clicked the name, and show the diff. Originally it made some sense to allow staging conflicting files, because git-gui did not provide any tools to resolve them from within the GUI. But now that we have added mergetool capabilities, it is more likely to cause accidental and non-undoable errors. Signed-off-by: Alexander Gavrilov <angavrilov@gmail.com> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* | git-gui: Support calling merge tools.Alexander Gavrilov2008-09-04
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Adds an item to the diff context menu in conflict mode, which invokes a merge tool for the selected file. Tool command-line handling code was ported from git-mergetool. Automatic default tool selection and custom merge tools are not supported. If merge.tool is not set, git-gui defaults to meld. This implementation uses a checkout-index hack in order to retrieve all stages with autocrlf and filters properly applied. It requires temporarily moving the original conflict file out of the way. Signed-off-by: Alexander Gavrilov <angavrilov@gmail.com> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* | git-gui: Support resolving conflicts via the diff context menu.Alexander Gavrilov2008-09-04
| | | | | | | | | | | | | | | | | | | | | | | | | | If the file has merge conflicts, show a special version of the diff context menu, which includes conflict resolution commands instead of Stage Hunk/Line. This patch only supports resolving by discarding all sides except one. Discarding is the only way to resolve conflicts involving symlinks and/or deletion, excluding manual editing. Signed-off-by: Alexander Gavrilov <angavrilov@gmail.com> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* | git-gui: Mark forgotten strings for translation.Christian Stimming2008-09-04
| | | | | | | | Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* | Merge branch 'maint'Shawn O. Pearce2008-09-01
|\ \ | |/ | | | | | | | | | | | | | | * maint: git-gui: Fix string escaping in po2msg.sh git gui: show diffs with a minimum of 1 context line Conflicts: lib/option.tcl
| * git-gui: Fix string escaping in po2msg.shAlexander Gavrilov2008-09-01
| | | | | | | | | | | | | | | | Escape '$', because otherwise git-gui crashes while trying to load malformed Japanese localization strings. Signed-off-by: Alexander Gavrilov <angavrilov@gmail.com> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
| * git gui: show diffs with a minimum of 1 context lineClemens Buchacher2008-09-01
| | | | | | | | | | | | | | | | | | | | | | | | Staging hunks without context does not work, because line number information would have to be recomputed for individual hunks. Since it is already possible to stage individual lines using 'Stage Line for Commit', zero context diffs are not really necessary for git gui. Signed-off-by: Clemens Buchacher <drizzd@aon.at> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* | git-gui: Allow specifying an initial line for git gui blame.Alexander Gavrilov2008-08-24
| | | | | | | | | | | | | | | | | | Add a command-line option to make git gui blame automatically scroll to a specific line in the file. Useful for integration with other tools. Signed-off-by: Alexander Gavrilov <angavrilov@gmail.com> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* | git-gui: Better positioning in Blame Parent CommitAlexander Gavrilov2008-08-24
| | | | | | | | | | | | | | | | | | Invoke diff-tree between the commit and its parent, and use the hunks to fix the target line number, accounting for addition and removal of lines. Signed-off-by: Alexander Gavrilov <angavrilov@gmail.com> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* | git-gui: Support passing blame to a parent commit.Alexander Gavrilov2008-08-24
| | | | | | | | | | | | | | | | | | | | Add a context menu item that switches the view to the parent of the commit under cursor. It is useful to see how the file looked before the change, and find older changes in the same lines. Signed-off-by: Alexander Gavrilov <angavrilov@gmail.com> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* | git-gui: Support starting gitk from Gui BlameAlexander Gavrilov2008-08-24
| | | | | | | | | | | | | | | | | | | | | | | | | | Add a context menu command to load commits that are within a certain time range from the selected commit into gitk. It can be useful for understanding of the code, especially if the repository is imported from a VCS that does not support atomic commits. Signed-off-by: Alexander Gavrilov <angavrilov@gmail.com> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* | git-gui: Teach git gui about file type changesGustaf Hendeby2008-08-24
|/ | | | | Signed-off-by: Gustaf Hendeby <hendeby@isy.liu.se> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* git-gui: update all remaining translations to French.Alexandre Bourget2008-08-12
| | | | | | | Simply.. Signed-off-by: Alexandre Bourget <alexandre.bourget@savoirfairelinux.com> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* git-gui: Update french translationAlexandre Bourget2008-08-12
| | | | | Signed-off-by: Alexandre Bourget <alexandre.bourget@savoirfairelinux.com> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* git-gui 0.11gitgui-0.11.0Shawn O. Pearce2008-08-10
| | | | Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* git-gui: Adapt discovery of oguilib to execdir 'libexec/git-core'Johannes Sixt2008-08-04
| | | | | | | | | | | | | The new execdir is two levels below the root directory, while the old execdir 'bin' was only one level below. This commit adapts the discovery of oguilib that uses relative paths accordingly. We determine whether we have the extra level in the same way in which the Makefile defines sharedir, i.e. whether the last directory part is 'git-core'. Inspired-by: Steffen Prohaska <prohaska@zib.de> Signed-off-by: Johannes Sixt <johannes.sixt@telecom.at> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* git-gui: add a part about format strings in po/READMEMichele Ballabio2008-08-03
| | | | | | | | | | This should help tranlators that need to reorder words and strings. Original explanation by Christian Stimming. Also remove unneeded backslashes. Signed-off-by: Michele Ballabio <barra_cuda@katamail.com> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* git-gui: update po/it.poMichele Ballabio2008-08-03
| | | | | Signed-off-by: Michele Ballabio <barra_cuda@katamail.com> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* git-gui: update Japanese translationしらいしななこ2008-08-03
| | | | | | | This updates Japanese translation to match the updated git-gui.pot. Signed-off-by: しらいしななこ <nanako3@lavabit.com> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* git-gui: Update swedish translation.Mikael Magnusson2008-08-02
| | | | Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
* git-gui: Update git-gui.pot for 0.11 nearing releaseShawn O. Pearce2008-08-02
| | | | Signed-off-by: Shawn O. Pearce <spearce@spearce.org>