git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: What's cooking in git.git (Aug 2016, #03; Mon, 8)

From
Lars Schneider <larsxschneider@gmail.com>
Date
Aug 10, 2016, 17:46 UTC
Message-ID
<4A236012-9645-424D-8E07-9E64DCFC2FFB@gmail.com>
In-Reply-To
<CAGZ79kai3V=pVMOsas6P9wSCyF=BXwVf2Piuci9CNt5BN=K7Wg@mail.gmail.com>
Show 58 quoted lines
> On 10 Aug 2016, at 19:36, Stefan Beller <sbeller@google.com> wrote:
> 
> On Wed, Aug 10, 2016 at 10:30 AM, Lars Schneider
> <larsxschneider@gmail.com> wrote:
>> 
>>> 
>>> * sb/submodule-update-dot-branch (2016-08-03) 7 commits
>>> (merged to 'next' on 2016-08-04 at 47bff41)
>>> + submodule update: allow '.' for branch value
>>> + submodule--helper: add remote-branch helper
>>> + submodule-config: keep configured branch around
>>> + submodule--helper: fix usage string for relative-path
>>> + submodule update: narrow scope of local variable
>>> + submodule update: respect depth in subsequent fetches
>>> + t7406: future proof tests with hard coded depth
>>> 
>>> A few updates to "git submodule update".
>>> 
>>> Will merge to 'master'.
>> 
>> I think "t7406: future proof tests with hard coded depth"
>> breaks the tests on OSX:
>> 
>> https://travis-ci.org/git/git/jobs/150779244
>> 
>> Cheers,
>> Lars
>> 
> 
> 
> error: pathspec '4' did not match any file(s) known to git.
> 
> not ok 46 - submodule update clone shallow submodule
> 
> #
> # test_when_finished "rm -rf super3" &&
> # first=$(git -C cloned submodule status submodule |cut -c2-41) &&
> # second=$(git -C submodule rev-parse HEAD) &&
> # commit_count=$(git -C submodule rev-list $first^..$second | wc -l) &&
> # git clone cloned super3 &&
> # pwd=$(pwd) &&
> # (
> # cd super3 &&
> # sed -e "s#url = ../#url = file://$pwd/#" <.gitmodules >.gitmodules.tmp &&
> # mv -f .gitmodules.tmp .gitmodules &&
> # git submodule update --init --depth=$commit_count &&
> # test 1 = $(git -C submodule log --oneline | wc -l)
> # )
> #
> 
> 
> Is it possible that the "wc -l" produces  SP <NUMBER> on OSX,
> such that the
> 
> # git submodule update --init --depth=$commit_count
> 
> contains "--depth= 4" which means empty depth and 4 as the pathspec
> for the update command?
Consider this:
~code/git git:(master) ▶ ls | wc -l
     747
Apparently `wc -l` adds 5 spaces on OS X...
- Lars
Previous: Stefan BellerNext: Stefan Beller
Message 10 of 15 in “What's cooking in git.git (Aug 2016, #03; Mon, 8)”
  1. Junio C HamanoAug 8, 2016
  2. Stefan BellerAug 8, 2016
  3. Junio C HamanoAug 9, 2016
  4. Elijah NewrenAug 9, 2016
  5. Junio C HamanoAug 9, 2016
  6. Johannes SchindelinAug 10, 2016
  7. Lars SchneiderAug 10, 2016
  8. Junio C HamanoAug 10, 2016
  9. Stefan BellerAug 10, 2016
  10. Lars SchneiderAug 10, 2016
  11. t7406: fix breakage on OSXStefan Beller, Aug 10, 2016
  12. Junio C HamanoAug 10, 2016
  13. Stefan BellerAug 10, 2016
  14. Junio C HamanoAug 10, 2016
  15. Lars SchneiderAug 10, 2016

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.