]> git.proxmox.com Git - libgit2.git/log
libgit2.git
11 years agoMore filesystem iterator tests
Russell Belfer [Thu, 18 Apr 2013 21:14:22 +0000 (14:14 -0700)]
More filesystem iterator tests

Refactors the helper function that builds a directory hierarchy
and then made use of it to try more variations on filesystem
iterator tests.

11 years agoMore filesystem iterator cleanup
Russell Belfer [Thu, 18 Apr 2013 21:13:53 +0000 (14:13 -0700)]
More filesystem iterator cleanup

Renamed the callback functions and made some minor rearrangements
to clean up the flow of some code.

11 years agoMake workdir iterator use filesystem iterator
Russell Belfer [Thu, 18 Apr 2013 18:11:38 +0000 (11:11 -0700)]
Make workdir iterator use filesystem iterator

This adds some hooks into the filesystem iterator so that the
workdir iterator can just become a wrapper around it.  Then we
remove most of the workdir iterator code and just have it augment
the filesystem iterator with skipping .git entries, updating the
ignore stack, and checking for submodules.

11 years agoAdd filesystem iterator variant
Russell Belfer [Wed, 17 Apr 2013 22:56:31 +0000 (15:56 -0700)]
Add filesystem iterator variant

This adds a new variant iterator that is a raw filesystem iterator
for scanning directories from a root.  There is still more work to
do to blend this with the working directory iterator.

11 years agoMerge pull request #1482 from nviennot/error-name-email
Vicent Martí [Thu, 18 Apr 2013 13:01:41 +0000 (06:01 -0700)]
Merge pull request #1482 from nviennot/error-name-email

Return error for empty name/email

11 years agotreebuilder: don't overwrite the error message
Carlos Martín Nieto [Thu, 18 Apr 2013 12:47:54 +0000 (14:47 +0200)]
treebuilder: don't overwrite the error message

11 years agoReturn error for empty name/email
Nicolas Viennot [Thu, 18 Apr 2013 04:55:20 +0000 (00:55 -0400)]
Return error for empty name/email

11 years agoMerge pull request #1478 from ethomson/win32_typechange_test
Vicent Martí [Wed, 17 Apr 2013 22:27:53 +0000 (15:27 -0700)]
Merge pull request #1478 from ethomson/win32_typechange_test

use a longer string for dummy data in test to avoid conflicting w/ index

11 years agouse a longer string for dummy data in test to avoid conflicting w/ index
Edward Thomson [Wed, 17 Apr 2013 22:21:17 +0000 (17:21 -0500)]
use a longer string for dummy data in test to avoid conflicting w/ index

11 years agorepository: Doc fix
Vicent Marti [Wed, 17 Apr 2013 22:15:08 +0000 (00:15 +0200)]
repository: Doc fix

11 years agoMerge pull request #1475 from libgit2/vmg/refs-peel
Vicent Martí [Wed, 17 Apr 2013 21:59:28 +0000 (14:59 -0700)]
Merge pull request #1475 from libgit2/vmg/refs-peel

Allow access to the cached peel data in packed-refs

11 years agorefs: Do not union the peel
Vicent Marti [Wed, 17 Apr 2013 21:29:34 +0000 (23:29 +0200)]
refs: Do not union the peel

11 years agorefs: Check alloc is cleaner
Vicent Marti [Wed, 17 Apr 2013 20:32:39 +0000 (22:32 +0200)]
refs: Check alloc is cleaner

11 years agoMerge pull request #1477 from ethomson/checkout_modified_use_cache
Vicent Martí [Wed, 17 Apr 2013 19:20:09 +0000 (12:20 -0700)]
Merge pull request #1477 from ethomson/checkout_modified_use_cache

checkout: use cache when possible to determine if workdir item is dirty

11 years agoMerge pull request #1476 from libgit2/vmg/bare-open
Vicent Martí [Wed, 17 Apr 2013 19:19:44 +0000 (12:19 -0700)]
Merge pull request #1476 from libgit2/vmg/bare-open

Add `git_repository_open_bare`

11 years agocheckout: use cache when possible to determine if workdir item is dirty
Edward Thomson [Wed, 17 Apr 2013 15:52:49 +0000 (10:52 -0500)]
checkout: use cache when possible to determine if workdir item is dirty

If the on-disk file has been staged (it's stat data matches the stat data
in the cache) then we need not hash the file to determine whether it
differs from the checkout target; instead we can simply use the oid in
the index.

This prevents recomputing a file's hash unnecessarily, prevents loading
the file (when filtering) and prevents edge cases where filters suggest
that a file is dirty immediately after git writes the file.

11 years agorefs: Add `git_referene_target_peel`
Vicent Marti [Wed, 17 Apr 2013 15:33:51 +0000 (17:33 +0200)]
refs: Add `git_referene_target_peel`

11 years agoMerge pull request #1474 from ghedo/development
Vicent Martí [Wed, 17 Apr 2013 12:39:54 +0000 (05:39 -0700)]
Merge pull request #1474 from ghedo/development

Update link to Perl bindings

11 years agoUpdate link to Perl bindings
Alessandro Ghedini [Wed, 17 Apr 2013 11:48:26 +0000 (13:48 +0200)]
Update link to Perl bindings

11 years agoAdd mailmap entries for me
Carlos Martín Nieto [Wed, 17 Apr 2013 09:03:18 +0000 (11:03 +0200)]
Add mailmap entries for me

11 years agorepository: Add `git_repository_open_bare`
Vicent Marti [Wed, 17 Apr 2013 02:46:37 +0000 (04:46 +0200)]
repository: Add `git_repository_open_bare`

11 years ago/mailmap me
Ben Straub [Tue, 16 Apr 2013 20:25:38 +0000 (13:25 -0700)]
/mailmap me

11 years agolibgit2 0.18.0 "Big Ben"
Vicent Marti [Tue, 16 Apr 2013 15:39:43 +0000 (17:39 +0200)]
libgit2 0.18.0 "Big Ben"

This is the last minor release before 1.0preview1.

Highlights of this release include:

- Branch API
- Checkout head, index and tree
- Finished clone support
- Abstracted reference API to use custom backends
- Full diff support
- New (faster) packbuilder
- Push support
- New Remotes API
- Revparse support (single and range commits)
- Stash support
- Submodules support

As always, the full changelog is available at:

http://libgit2.github.com/libgit2/#p/changelog

Yeah, it's a huge release. Releasing stuff sucks.
Expect 1.0 and API freeze in less than a month.

Your faithful maintainer,
 vmg

Signed-off-by: Vicent Marti <tanoku@gmail.com>
11 years agoMerge pull request #1469 from libgit2/vmg/unified-revision
Vicent Martí [Mon, 15 Apr 2013 22:47:38 +0000 (15:47 -0700)]
Merge pull request #1469 from libgit2/vmg/unified-revision

Unified rev-parse, with a revision object

11 years agoMerge pull request #1470 from carlosmn/remote-ls-after-close
Vicent Martí [Mon, 15 Apr 2013 22:27:27 +0000 (15:27 -0700)]
Merge pull request #1470 from carlosmn/remote-ls-after-close

Fetch fixes

11 years agoFix examples
Vicent Marti [Mon, 15 Apr 2013 22:17:40 +0000 (00:17 +0200)]
Fix examples

11 years agoremote: don't try to update FETCH_HEAD if no extra heads exist
Carlos Martín Nieto [Mon, 15 Apr 2013 22:11:59 +0000 (00:11 +0200)]
remote: don't try to update FETCH_HEAD if no extra heads exist

Don't try to update anything if there are no heads to update. This
saves us from trying to look into a fetch refspec when there is none.

A better fix for compatibility with git when using remotes without
refspecs is still needed, but this stops us from segfaulting.

11 years agoUpdate docs
Vicent Marti [Mon, 15 Apr 2013 21:54:28 +0000 (23:54 +0200)]
Update docs

11 years agogit_revision -> git_revspec
Vicent Marti [Mon, 15 Apr 2013 21:40:46 +0000 (23:40 +0200)]
git_revision -> git_revspec

11 years agoIs this crazy?
Vicent Marti [Mon, 15 Apr 2013 21:32:40 +0000 (23:32 +0200)]
Is this crazy?

11 years agoAllow git_remote_ls after disconnecting from the remote
Carlos Martín Nieto [Mon, 15 Apr 2013 20:53:57 +0000 (22:53 +0200)]
Allow git_remote_ls after disconnecting from the remote

Keep the data around until free, as expected by our own fetch example

11 years agoMerge remote-tracking branch 'ben/unified-revparse' into development
Vicent Marti [Mon, 15 Apr 2013 21:18:24 +0000 (23:18 +0200)]
Merge remote-tracking branch 'ben/unified-revparse' into development

11 years agoClean up minor details
Ben Straub [Mon, 15 Apr 2013 20:29:40 +0000 (13:29 -0700)]
Clean up minor details

11 years agoClean up example code.
Ben Straub [Mon, 15 Apr 2013 19:10:18 +0000 (12:10 -0700)]
Clean up example code.

11 years agoChange git_revparse to output git_object pointers
Ben Straub [Mon, 15 Apr 2013 19:00:04 +0000 (12:00 -0700)]
Change git_revparse to output git_object pointers

This will probably prevent many lookup/free
operations in calling code.

11 years agoRedeploy git_revparse_single.
Ben Straub [Mon, 15 Apr 2013 18:57:24 +0000 (11:57 -0700)]
Redeploy git_revparse_single.

11 years agoReintroduce git_revparse_single.
Ben Straub [Mon, 15 Apr 2013 18:42:34 +0000 (11:42 -0700)]
Reintroduce git_revparse_single.

11 years agoMerge pull request #1468 from carlosmn/obsd-sparc64
Vicent Martí [Mon, 15 Apr 2013 18:19:12 +0000 (11:19 -0700)]
Merge pull request #1468 from carlosmn/obsd-sparc64

OpenBSD & sparc64 fixes

11 years agorefdb tests: use the right variable size
Carlos Martín Nieto [Mon, 15 Apr 2013 18:20:14 +0000 (20:20 +0200)]
refdb tests: use the right variable size

Mixing int and size_t through pointers leads to problems
in big-endian machines.

11 years agoFix compilation on OpenBSD
Carlos Martín Nieto [Mon, 15 Apr 2013 18:00:42 +0000 (20:00 +0200)]
Fix compilation on OpenBSD

11 years agoMerge pull request #1467 from carlosmn/commit-parse
Vicent Martí [Mon, 15 Apr 2013 13:11:29 +0000 (06:11 -0700)]
Merge pull request #1467 from carlosmn/commit-parse

commit: correctly detect the start of the commit message

11 years agocommit: correctly detect the start of the commit message
Carlos Martín Nieto [Mon, 15 Apr 2013 10:24:08 +0000 (12:24 +0200)]
commit: correctly detect the start of the commit message

The end of the header is signaled by to consecutive LFs and the commit
message starts immediately after. Jumping over LFs at the start of the
message is a bug and leads to creating different commits if
when rebuilding history.

This also fixes an empty commit message being returned as "\n".

11 years agoMerge pull request #1464 from ethomson/refdb_free
Russell Belfer [Fri, 12 Apr 2013 17:48:23 +0000 (10:48 -0700)]
Merge pull request #1464 from ethomson/refdb_free

dec refcount on refdb instead of always freeing

11 years agodec refcount on refdb instead of always freeing
Edward Thomson [Thu, 4 Apr 2013 16:38:17 +0000 (11:38 -0500)]
dec refcount on refdb instead of always freeing

11 years agoMerge pull request #1450 from carlosmn/branch-upstream
Vicent Martí [Thu, 11 Apr 2013 13:34:59 +0000 (06:34 -0700)]
Merge pull request #1450 from carlosmn/branch-upstream

Branch upstream configuration

11 years agobranch: add more upstream configuration management
Carlos Martín Nieto [Sat, 30 Mar 2013 03:27:42 +0000 (04:27 +0100)]
branch: add more upstream configuration management

Add functions to set and unset the upstream configuration to
complement the getter we already have.

11 years agoMerge pull request #1367 from yorah/fix/pathspecs_behaviour
Vicent Martí [Thu, 11 Apr 2013 10:03:02 +0000 (03:03 -0700)]
Merge pull request #1367 from yorah/fix/pathspecs_behaviour

Correctly return matched pathspec when passing "*" or "."

11 years agoNotify '*' pathspec correctly when diffing
yorah [Mon, 4 Mar 2013 10:31:50 +0000 (11:31 +0100)]
Notify '*' pathspec correctly when diffing

I also moved all tests related to notifying in their own file.

11 years agoobject: Export git_object_dup
Vicent Marti [Wed, 10 Apr 2013 14:55:29 +0000 (16:55 +0200)]
object: Export git_object_dup

11 years agoMerge pull request #1424 from phkelley/efficient_push
Vicent Martí [Wed, 10 Apr 2013 15:33:33 +0000 (08:33 -0700)]
Merge pull request #1424 from phkelley/efficient_push

Reduce the number of unnecessary objects in pushed packs

11 years agoexamples: Don't print weird characters
Vicent Marti [Wed, 10 Apr 2013 14:41:05 +0000 (16:41 +0200)]
examples: Don't print weird characters

11 years agoMerge pull request #1460 from arrbee/fix-dirty-submodules-diff
Vicent Martí [Tue, 9 Apr 2013 22:15:18 +0000 (15:15 -0700)]
Merge pull request #1460 from arrbee/fix-dirty-submodules-diff

Submodule diff tests and fixes

11 years agoTests and more fixes for submodule diffs
Russell Belfer [Tue, 9 Apr 2013 21:52:32 +0000 (14:52 -0700)]
Tests and more fixes for submodule diffs

This adds tests for diffs with submodules in them and (perhaps
unsurprisingly) requires further fixes to be made.  Specifically,
this fixes:

- when considering if a submodule is dirty in the workdir, it was
  being treated as dirty even if only the index was dirty.
- git_diff_patch_to_str (and git_diff_patch_print) were "printing"
  the headers for files (and submodules) that were unmodified or
  had no meaningful content.
- added comment to previous fix and removed unneeded parens.

11 years agoFix clang warnings and improve checks
Russell Belfer [Tue, 9 Apr 2013 18:40:00 +0000 (11:40 -0700)]
Fix clang warnings and improve checks

11 years agoFix submodule dirty states not showing if submodules comes before files, or there...
Linquize [Fri, 29 Mar 2013 03:52:18 +0000 (11:52 +0800)]
Fix submodule dirty states not showing if submodules comes before files, or there are only dirty submodules but no changed files

GIT_DIFF_PATCH_DIFFABLE was not set, so the diff content was not shown

When submodule is dirty, the hash may be the same, but the length is different because -dirty is appended

We can therefore compare the length or hash

11 years agoMerge pull request #1458 from maxpow4h/patch-1
Vicent Martí [Tue, 9 Apr 2013 06:28:27 +0000 (23:28 -0700)]
Merge pull request #1458 from maxpow4h/patch-1

Updated link to Haskell bindings

11 years agoAdd rev-list example to makefiles
Ben Straub [Tue, 9 Apr 2013 01:07:12 +0000 (05:07 +0400)]
Add rev-list example to makefiles

11 years agoDeprecate git_revparse_single and _rangelike
Ben Straub [Tue, 9 Apr 2013 01:03:51 +0000 (05:03 +0400)]
Deprecate git_revparse_single and _rangelike

11 years agoUpdated link to Haskell bindings
Maxwell Swadling [Mon, 8 Apr 2013 23:28:40 +0000 (09:28 +1000)]
Updated link to Haskell bindings

The old one hasn't been updated in a long time. This one is current.

11 years agoImplement unified git_revparse
Ben Straub [Tue, 12 Mar 2013 03:27:16 +0000 (20:27 -0700)]
Implement unified git_revparse

11 years agoPropose unified rev-parse API
Ben Straub [Mon, 11 Mar 2013 20:20:47 +0000 (13:20 -0700)]
Propose unified rev-parse API

11 years agotest: Add missing NULLs
Vicent Marti [Sun, 7 Apr 2013 05:23:08 +0000 (07:23 +0200)]
test: Add missing NULLs

11 years agoMerge remote-tracking branch 'gnprice/revwalk' into development
Vicent Marti [Sun, 7 Apr 2013 05:22:38 +0000 (07:22 +0200)]
Merge remote-tracking branch 'gnprice/revwalk' into development

11 years agoexamples: a test, for rev-list
Greg Price [Wed, 20 Mar 2013 16:39:20 +0000 (09:39 -0700)]
examples: a test, for rev-list

This test file could probably be improved by a framework like
the one in git.git:t/, or by using a language like Python instead
of shell.

The other examples would benefit from tests too.  Probably best
to settle on a framework to write them in, then add more tests.

Signed-off-by: Greg Price <price@mit.edu>
11 years agoexamples: rev-list
Greg Price [Sun, 31 Mar 2013 21:56:32 +0000 (14:56 -0700)]
examples: rev-list

This demonstrates parts of the interface for specifying revisions that
Git users are familiar with from 'git rev-list', 'git log', and other
Git commands.  A similar query interface is used in out-of-core
command-line programs that browse a Git repo (like 'tig'), and may be
useful for an 'advanced search' interface in GUI or web applications.

In this version, we parse all the query modifiers we can support with
the existing logic in revwalk: basic include/exclude commits, and the
ordering flags.  More logic will be required to support '--grep',
'--author', the pickaxe '-S', etc.

Signed-off-by: Greg Price <price@mit.edu>
11 years agorevwalk: Parse revision ranges
Greg Price [Mon, 4 Mar 2013 04:54:23 +0000 (20:54 -0800)]
revwalk: Parse revision ranges

All the hard work is already in revparse.

Signed-off-by: Greg Price <price@mit.edu>
11 years agorevparse: Parse range-like syntax
Greg Price [Wed, 20 Mar 2013 17:01:58 +0000 (10:01 -0700)]
revparse: Parse range-like syntax

Signed-off-by: Greg Price <price@mit.edu>
11 years agoMerge pull request #1456 from ben/fix-general-example
Vicent Martí [Thu, 4 Apr 2013 18:46:54 +0000 (11:46 -0700)]
Merge pull request #1456 from ben/fix-general-example

Fix the general.c example to run against testrepo.git

11 years agoGeneral example: run against testrepo.git
Ben Straub [Thu, 4 Apr 2013 18:44:50 +0000 (11:44 -0700)]
General example: run against testrepo.git

Fixes #1455

11 years agoMerge pull request #1453 from ethomson/refdb_export
Vicent Martí [Wed, 3 Apr 2013 00:09:35 +0000 (17:09 -0700)]
Merge pull request #1453 from ethomson/refdb_export

Properly GIT_EXPORT git_reference__alloc

11 years agoexport git_reference__alloc
Edward Thomson [Tue, 2 Apr 2013 23:57:42 +0000 (18:57 -0500)]
export git_reference__alloc

11 years agoMerge pull request #1452 from nulltoken/fix/branch_doc
Ben Straub [Mon, 1 Apr 2013 20:28:08 +0000 (13:28 -0700)]
Merge pull request #1452 from nulltoken/fix/branch_doc

branch: Fix git_branch_create() documentation

11 years agobranch: Fix git_branch_create() documentation
nulltoken [Mon, 1 Apr 2013 20:01:13 +0000 (22:01 +0200)]
branch: Fix git_branch_create() documentation

11 years agoMerge pull request #1448 from phkelley/development
Vicent Martí [Mon, 1 Apr 2013 14:12:49 +0000 (07:12 -0700)]
Merge pull request #1448 from phkelley/development

Avoid pre-Win7 WinHTTP self-redirect quirk

11 years agoFix whitespace in src/win32/version.h
Philip Kelley [Mon, 1 Apr 2013 03:04:14 +0000 (23:04 -0400)]
Fix whitespace in src/win32/version.h

11 years agoAdd git_has_win32_version helper
Philip Kelley [Mon, 1 Apr 2013 02:22:33 +0000 (22:22 -0400)]
Add git_has_win32_version helper

11 years agorevwalk: refactor tests a bit
Greg Price [Mon, 4 Mar 2013 10:17:04 +0000 (02:17 -0800)]
revwalk: refactor tests a bit

Signed-off-by: Greg Price <price@mit.edu>
11 years agorevwalk tests: better diagram of example repo
Greg Price [Tue, 19 Mar 2013 19:02:19 +0000 (12:02 -0700)]
revwalk tests: better diagram of example repo

The purported command output was already inaccurate, as the refs
aren't where it shows.  In any event, the labels a reader of this
file really needs are the indices used in commit_sorting_*, to make
it possible to understand them by referring directly from those
arrays to the diagram rather than from the index arrays, to commit_ids,
to the diagram.  Add those.

Signed-off-by: Greg Price <price@mit.edu>
11 years agoFix puzzling doc comment
Greg Price [Mon, 4 Mar 2013 04:22:51 +0000 (20:22 -0800)]
Fix puzzling doc comment

Signed-off-by: Greg Price <price@mit.edu>
11 years agoMerge pull request #1451 from nulltoken/topic/support_taggerless_tags
Vicent Martí [Sun, 31 Mar 2013 21:07:15 +0000 (14:07 -0700)]
Merge pull request #1451 from nulltoken/topic/support_taggerless_tags

Support tags with no tagger nor message

11 years agoWin32 error reporting: Support WinHTTP errors
Philip Kelley [Sun, 31 Mar 2013 16:10:27 +0000 (12:10 -0400)]
Win32 error reporting: Support WinHTTP errors

11 years agotag: Fix parsing when no tagger nor message
nulltoken [Sun, 31 Mar 2013 11:27:43 +0000 (13:27 +0200)]
tag: Fix parsing when no tagger nor message

11 years agotests: Fix indentations
nulltoken [Sun, 31 Mar 2013 11:53:40 +0000 (13:53 +0200)]
tests: Fix indentations

11 years agobranch: refactor git_branch_remote_name
Carlos Martín Nieto [Sat, 30 Mar 2013 08:30:29 +0000 (09:30 +0100)]
branch: refactor git_branch_remote_name

Return the size we'd need to write to instead of simply an
error. Split the function into two to be used later by the upstream
configuration functions.

11 years agoAvoid pre-Win7 WinHTTP self-redirect quirk
Philip Kelley [Sun, 31 Mar 2013 01:36:04 +0000 (21:36 -0400)]
Avoid pre-Win7 WinHTTP self-redirect quirk

11 years agobranch: rename 'tracking' to 'upstream'
Carlos Martín Nieto [Sat, 30 Mar 2013 02:39:19 +0000 (03:39 +0100)]
branch: rename 'tracking' to 'upstream'

The term 'tracking' is overloaded. Help distinguish what we mean by
using 'upstream' for this part of the library.

11 years agotransport: don't try to export nonexistent function
Carlos Martín Nieto [Sat, 30 Mar 2013 03:50:53 +0000 (04:50 +0100)]
transport: don't try to export nonexistent function

11 years agoMerge pull request #1446 from ethomson/free
Edward Thomson [Fri, 29 Mar 2013 23:44:00 +0000 (16:44 -0700)]
Merge pull request #1446 from ethomson/free

Clean up some memleaks in tests

11 years agofree!
Edward Thomson [Fri, 29 Mar 2013 23:36:11 +0000 (18:36 -0500)]
free!

11 years agoMerge pull request #1445 from ethomson/reset_unmerged
Vicent Martí [Fri, 29 Mar 2013 17:13:54 +0000 (10:13 -0700)]
Merge pull request #1445 from ethomson/reset_unmerged

remove unmerged files during reset hard

11 years agoremove unmerged files during reset hard
Edward Thomson [Fri, 29 Mar 2013 16:26:12 +0000 (11:26 -0500)]
remove unmerged files during reset hard

11 years agoFix Windows/Win32 warning
Russell Belfer [Tue, 26 Mar 2013 19:27:15 +0000 (12:27 -0700)]
Fix Windows/Win32 warning

11 years agoMerge pull request #1436 from schu/opts-cache-size
Vicent Martí [Tue, 26 Mar 2013 18:05:57 +0000 (11:05 -0700)]
Merge pull request #1436 from schu/opts-cache-size

opts: allow configuration of odb cache size

11 years agoMerge pull request #1439 from arrbee/recurse-ignored-dirs
Vicent Martí [Tue, 26 Mar 2013 17:42:30 +0000 (10:42 -0700)]
Merge pull request #1439 from arrbee/recurse-ignored-dirs

Several diff and status fixes

11 years agoFix some diff ignores and submodule dirty workdir
Russell Belfer [Tue, 26 Mar 2013 06:58:40 +0000 (23:58 -0700)]
Fix some diff ignores and submodule dirty workdir

This started out trying to look at the problems from issue #1425
and gradually grew to a broader set of fixes.  There are two core
things fixed here:

1. When you had an ignore like "/bin" which is rooted at the top
   of your tree, instead of immediately adding the "bin/" entry
   as an ignored item in the diff, we were returning all of the
   direct descendants of the directory as ignored items.  This
   changes things to immediately ignore the directory.  Note that
   this effects the behavior in test_status_ignore__subdirectories
   so that we no longer exactly match core gits ignore behavior,
   but the new behavior probably makes more sense (i.e. we now
   will include an ignored directory inside an untracked directory
   that we previously would have left off).
2. When a submodule only contained working directory changes, the
   diff code was always considering it unmodified which was just
   an outright bug. The HEAD SHA of the submodule matches the SHA
   in the parent repo index, and since the SHAs matches, the diff
   code was overwriting the actual status with UNMODIFIED.

These fixes broke existing tests test_diff_workdir__submodules and
test_status_ignore__subdirectories but looking it over, I actually
think the new results are correct and the old results were wrong.
@nulltoken had actually commented on the subdirectory ignore issue
previously.

I also included in the tests some debugging versions of the
shared iteration callback routines that print status or diff
information.  These aren't used actively in the tests, but can be
quickly swapped in to test code to give a better picture of what
is being scanned in some of the complex test scenarios.

11 years agoImplement GIT_STATUS_OPT_EXCLUDE_SUBMODULES
Russell Belfer [Tue, 26 Mar 2013 05:19:39 +0000 (22:19 -0700)]
Implement GIT_STATUS_OPT_EXCLUDE_SUBMODULES

This option has been sitting unimplemented for a while, so I
finally went through and implemented it along with some tests.

As part of this, I improved the implementation of
GIT_DIFF_IGNORE_SUBMODULES so it be more diligent about avoiding
extra work and about leaving off delta records for submodules to
the greatest extent possible (though it may include them still
if you are request TYPECHANGE records).

11 years agoMerge pull request #1438 from ethomson/checkout_stat
Vicent Martí [Tue, 26 Mar 2013 04:46:51 +0000 (21:46 -0700)]
Merge pull request #1438 from ethomson/checkout_stat

don't stat until the file is written

11 years agodon't stat until the file is written
Edward Thomson [Tue, 26 Mar 2013 01:16:02 +0000 (18:16 -0700)]
don't stat until the file is written

11 years agoRecursing into ignored dirs for diff and status
Russell Belfer [Mon, 25 Mar 2013 23:40:16 +0000 (16:40 -0700)]
Recursing into ignored dirs for diff and status

This implements working versions of GIT_DIFF_RECURSE_IGNORED_DIRS
and GIT_STATUS_OPT_RECURSE_IGNORED_DIRS along with some tests for
the newly available behaviors.  This is not turned on by default
for status, but can be accessed via the options to the extended
version of the command.

11 years agoMerge pull request #1437 from phkelley/redirect
Vicent Martí [Mon, 25 Mar 2013 22:30:37 +0000 (15:30 -0700)]
Merge pull request #1437 from phkelley/redirect

http: Support 302 Found (arrbee did most of the work)