Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Commits on Jul 19, 2012
  1. @thenigan @gitster

    difftool: only copy back files modified during directory diff

    thenigan authored gitster committed
    When 'difftool --dir-diff' is used to compare working tree files,
    it always copies files from the tmp dir back to the working tree
    when the diff tool is closed, even if the files were not modified
    by the diff tool.
    
    This causes the file timestamp to change. Files should only be
    copied from the tmp dir back to the working copy if they were
    actually modified.
    
    Signed-off-by: Tim Henigan <tim.henigan@gmail.com>
    Signed-off-by: David Aguilar <davvid@gmail.com>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
Commits on Jun 22, 2012
  1. @thenigan @gitster

    diff-no-index: exit(1) if 'diff --quiet <repo file> <external file>' …

    thenigan authored gitster committed
    …finds changes
    
    When running 'git diff --quiet <file1> <file2>', if file1 or file2
    is outside the repository, it will exit(0) even if the files differ.
    It should exit(1) when they differ.
    
    This happens because 'diff_no_index' looks at the 'found_changes'
    member from 'diff_options' to determine if changes were made.  This
    is the wrong thing to do, since it is only set if xdiff is actually
    run and it finds a change (the diff machinery will optimize out the
    xdiff call when it is not necessary) and in that case HAS_CHANGED
    flag needs to be taken into account.
    
    Use diff_result_code() that knows all these details for the correct
    exit value instead.
    
    Signed-off-by: Tim Henigan <tim.henigan@gmail.com>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
Commits on Apr 23, 2012
  1. @thenigan @gitster

    difftool: print list of valid tools with '--tool-help'

    thenigan authored gitster committed
    Since bc7a96a (mergetool--lib: Refactor tools into separate files,
    2011-08-18), it is possible to add a new diff tool by creating a simple
    script in the '$(git --exec-path)/mergetools' directory.  Updating the
    difftool help text is still a manual process, and the documentation can
    easily go out of sync.
    
    This commit teaches difftool the '--tool-help' option, which:
      - Reads the list of valid tools from 'mergetools/*'
      - Determines which of them are actually installed
      - Determines which are capable of diffing (i.e. not just a merge tool)
      - Prints the resulting list for the user
    
    Signed-off-by: Tim Henigan <tim.henigan@gmail.com>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
  2. @thenigan @gitster

    difftool: teach difftool to handle directory diffs

    thenigan authored gitster committed
    When 'difftool' is called to compare a range of commits that modify
    more than one file, it opens a separate instance of the diff tool for
    each file that changed.
    
    The new '--dir-diff' option copies all the modified files to a temporary
    location and runs a directory diff on them in a single instance of the
    diff tool.
    
    Signed-off-by: Tim Henigan <tim.henigan@gmail.com>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
Commits on Mar 23, 2012
  1. @thenigan @gitster

    difftool: eliminate setup_environment function

    thenigan authored gitster committed
    Removing this function shortens the code and makes it easier to read.
    Now all environment variables are set as part of procedural operation.
    
    Signed-off-by: Tim Henigan <tim.henigan@gmail.com>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
  2. @thenigan @gitster

    difftool: stop appending '.exe' to git

    thenigan authored gitster committed
    The system call to Git works the same whether or not ".exe" is
    appended to "git". The extra code is not necessary.
    
    Signed-off-by: Tim Henigan <tim.henigan@gmail.com>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
  3. @thenigan @gitster

    difftool: remove explicit change of PATH

    thenigan authored gitster committed
    Adding the script directory to PATH is not needed. The script is
    located at '$(git --exec-path)', which is already on the PATH.
    
    Signed-off-by: Tim Henigan <tim.henigan@gmail.com>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
  4. @thenigan @gitster

    difftool: exit(0) when usage is printed

    thenigan authored gitster committed
    Prior to this commit, the script exited with an error whenever the
    usage string was printed, regardless of the reason it was done. In
    cases where usage was printed due to a user request (e.g. '-h'
    option), the script should exit without error (exit 0).
    
    This commit adds an argument to the usage function that allows the
    exit code to be specified when the function is called.
    
    Signed-off-by: Tim Henigan <tim.henigan@gmail.com>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
  5. @thenigan @gitster

    difftool: add '--no-gui' option

    thenigan authored gitster committed
    This commit teaches difftool to handle the '--no-gui' option. This option
    negates the existing '--gui' option. The last setting given on the command
    line wins.
    
    This allows a user to configure "[alias] mdt = difftool --gui", but still
    have the ability to override the setting without error:
    
    $ git mdt --no-gui
    
    Signed-off-by: Tim Henigan <tim.henigan@gmail.com>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
  6. @thenigan @gitster

    difftool: parse options using Getopt::Long

    thenigan authored gitster committed
    Replace custom option/argument parser with standard Getopt::Long
    module.  This shortens the code and makes it easier to understand.
    
    Signed-off-by: Tim Henigan <tim.henigan@gmail.com>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
Commits on Mar 15, 2012
  1. @thenigan @gitster

    Documentation/difftool: add deltawalker to list of valid diff tools

    thenigan authored gitster committed
    deltawalker has been supported since 284a126, but was not added
    to the list of valid diff tools reported by 'git difftool --help'.
    
    Signed-off-by: Tim Henigan <tim.henigan@gmail.com>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
Commits on Mar 14, 2012
  1. @thenigan @gitster

    contrib/diffall: fix cleanup trap on Windows

    thenigan authored gitster committed
    Prior to this commit, the cleanup trap that removes the tmp dir
    created by the script would fail on Windows. The error was silently
    ignored by the script.
    
    On Windows, a directory cannot be removed while it is the working
    directory of the process (thanks to Johannes Sixt on the Git list
    for this info [1]).
    
    This commit eliminates the 'cd' into the tmp directory that caused
    the error.
    
    [1]: http://article.gmane.org/gmane.comp.version-control.git/193086
    
    Signed-off-by: Tim Henigan <tim.henigan@gmail.com>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
  2. @thenigan @gitster

    contrib/diffall: eliminate duplicate while loops

    thenigan authored gitster committed
    There were 3 instances of a 'while read; do' that used identical logic
    to populate '/tmp/right_dir'. This commit groups them into a single loop.
    
    Signed-off-by: Tim Henigan <tim.henigan@gmail.com>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
  3. @thenigan @gitster

    contrib/diffall: eliminate use of tar

    thenigan authored gitster committed
    The 'tar' utility is not available on all platforms (some only support
    'gnutar').  An earlier commit created a work-around for this problem,
    but a better solution is to eliminate the use of 'tar' completely.
    
    Signed-off-by: Tim Henigan <tim.henigan@gmail.com>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
  4. @thenigan @gitster

    contrib/diffall: create tmp dirs without mktemp

    thenigan authored gitster committed
    mktemp is not available on all platforms.  Instead of littering the code
    with a work-around, this commit replaces mktemp with a one-line Perl
    script.
    
    Signed-off-by: Tim Henigan <tim.henigan@gmail.com>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
  5. @thenigan @gitster

    contrib/diffall: comment actual reason for 'cdup'

    thenigan authored gitster committed
    The comment from an earlier commit did not reflect the actual reason this
    operation is needed.
    
    Signed-off-by: Tim Henigan <tim.henigan@gmail.com>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
  6. @thenigan @gitster

    Documentation/diff-options: reword description of --submodule option

    thenigan authored gitster committed
    The previous description was confusing.  This rewrite makes it easier
    to understand.
    
    Signed-off-by: Tim Henigan <tim.henigan@gmail.com>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
Commits on Mar 5, 2012
  1. @thenigan @gitster

    mergetools: add a plug-in to support DeltaWalker

    thenigan authored gitster committed
    DeltaWalker is a non-free tool popular among some users.  Add a
    plug-in to support it from difftool and mergetool.
    
    Note that the $(pwd)/ in front of $MERGED should not be necessary.
    However without it, DeltaWalker crashes with a JRE exception.
    
    Signed-off-by: Tim Henigan <tim.henigan@gmail.com>
    Helped-by: David Aguilar <davvid@gmail.com>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
Commits on Feb 27, 2012
  1. @thenigan @gitster

    CodingGuidelines: do not use 'which' in shell scripts

    thenigan authored gitster committed
    During the code review of a recent patch, it was noted that shell scripts
    must not use 'which $cmd' to check the availability of the command $cmd.
    The output of the command is not machine parseable and its exit code is
    not reliable across platforms.
    
    It is better to use 'type' to accomplish this task.
    
    Signed-off-by: Tim Henigan <tim.henigan@gmail.com>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
  2. @thenigan @gitster

    CodingGuidelines: Add a note about spaces after redirection

    thenigan authored gitster committed
    During code review of some patches, it was noted that redirection operators
    should have space before, but no space after them.
    
    Signed-off-by: Tim Henigan <tim.henigan@gmail.com>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
  3. @thenigan @gitster

    contrib: add git-diffall script

    thenigan authored gitster committed
    The 'git difftool' allows the user to view diffs using an external tool.
    It runs a separate instance of the tool for each file in the diff. This
    makes it tedious to review changes spanning multiple files.
    
    The 'git-diffall' script instead prepares temporary directories with the
    files to be compared and launches a single instance of the external diff
    tool to view them (i.e. a directory diff).
    
    The 'diff.tool' or 'merge.tool' configuration variable is used to specify
    which external tool is used.
    
    Signed-off-by: Tim Henigan <tim.henigan@gmail.com>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
Commits on Jun 1, 2010
  1. @thenigan @gitster

    Documentation/SubmittingPatches: Fix typo in GMail section

    thenigan authored gitster committed
    Commit e498257 introduced a typo while improving the GMail section
    of SubmittingPatches.
    
    Signed-off-by: Tim Henigan <tim.henigan@gmail.com>
    Acked-by: Michael J Gruber <git@drmicha.warpmail.net>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
Commits on Nov 21, 2009
  1. @thenigan @gitster

    git remote: Separate usage strings for subcommands

    thenigan authored gitster committed
    When the usage string for a subcommand must be printed,
    only print the information relevant to that command.
    
    This commit also removes the complete options list from
    the first line of the subcommand usage string. Instead,
    individual options are documented in the detailed
    description following the general usage line.
    
    Signed-off-by: Tim Henigan <tim.henigan@gmail.com>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
Commits on Nov 15, 2009
  1. @thenigan @gitster

    Update 'git remote update' usage string to match man page.

    thenigan authored gitster committed
    Commit b344e16 taught 'git remote update' to understand
    [group | remote] as its argument.  The man page was updated
    to document this change, but the usage string was not.
    
    Signed-off-by: Tim Henigan <tim.henigan@gmail.com>
    Signed-off-by: Junio C Hamano <gitster@pobox.com>
Something went wrong with that request. Please try again.