Merge branch 'master' into crash-on-lfs-checkout

This commit is contained in:
brian m. carlson 2019-12-06 20:25:33 +00:00 committed by GitHub
commit 686939a3ab
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
12 changed files with 126 additions and 15 deletions

38
.github/ISSUE_TEMPLATE/bug_report.md vendored Normal file

@ -0,0 +1,38 @@
---
name: Bug report
about: Create a report to help us improve
title: ''
labels: ''
assignees: ''
---
**Describe the bug**
A clear and concise description of what the bug is.
**To Reproduce**
Steps to reproduce the behavior:
1. Go to '...'
2. Click on '....'
3. Scroll down to '....'
4. See error
**Expected behavior**
A clear and concise description of what you expected to happen.
**System environment**
The version of your operating system, plus any relevant information about platform or configuration (e.g., container or CI usage, Cygwin, WSL, or non-Basic authentication). If relevant, include the output of `git config -l` as a code block.
**Output of `git lfs env`**
The output of running `git lfs env` as a code block.
**Additional context**
Any other relevant context about the problem here.
<!--
Please note: if you're receiving a message from the server side (including a
`batch response` message), please contact your Git hosting provider. This
repository is for the Git LFS client only; problems with GitHub's server-side
LFS support should be reported to them as described in the `CONTRIBUTING.md`
file.
-->

28
.github/ISSUE_TEMPLATE/other-issue.md vendored Normal file

@ -0,0 +1,28 @@
---
name: Other issue
about: Ask a question, request a feature, or report something that's not a bug
title: ''
labels: ''
assignees: ''
---
**Describe the issue**
A clear and concise description of why you wrote in today.
**System environment**
The version of your operating system, plus any relevant information about platform or configuration (e.g., container or CI usage, Cygwin, WSL, or non-Basic authentication). If relevant, include the output of `git config -l` as a code block.
**Output of `git lfs env`**
The output of running `git lfs env` as a code block.
**Additional context**
Any other relevant context about the problem here.
<!--
Please note: if you're receiving a message from the server side (including a
`batch response` message), it's probably best to contact your Git hosting
provider about the problem. Also, this repository is for the Git LFS client
only; problems with GitHub's server-side LFS support should be reported to them
as described in the `CONTRIBUTING.md` file.
-->

@ -9,7 +9,7 @@ jobs:
os: [ubuntu-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@master
- uses: actions/checkout@v1
- run: script/cibuild
- run: make release
- run: mkdir -p bin/assets
@ -22,7 +22,7 @@ jobs:
name: Build on Windows
runs-on: windows-latest
steps:
- uses: actions/checkout@master
- uses: actions/checkout@v1
- run: mkdir -p "$HOME/go/bin"
shell: bash
- run: set GOPATH=%HOME%\go
@ -57,7 +57,7 @@ jobs:
os: [ubuntu-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@master
- uses: actions/checkout@v1
- run: git clone -b master https://github.com/git/git.git "$HOME/git"
- run: script/build-git "$HOME/git"
- run: script/cibuild
@ -68,7 +68,7 @@ jobs:
os: [ubuntu-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@master
- uses: actions/checkout@v1
- run: git clone -b v2.0.0 https://github.com/git/git.git "$HOME/git"
- run: script/build-git "$HOME/git"
- run: script/cibuild
@ -76,7 +76,7 @@ jobs:
name: Build Linux packages
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- uses: actions/checkout@v1
- uses: actions/setup-ruby@v1
- run: git clone https://github.com/git-lfs/build-dockers.git "$HOME/build-dockers"
- run: (cd "$HOME/build-dockers" && ./build_dockers.bsh)

@ -8,7 +8,7 @@ jobs:
name: Build Windows Assets
runs-on: windows-latest
steps:
- uses: actions/checkout@master
- uses: actions/checkout@v1
- uses: actions/setup-ruby@v1
- run: mkdir -p "$HOME/go/bin"
shell: bash
@ -46,7 +46,7 @@ jobs:
needs: build-windows
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- uses: actions/checkout@v1
- uses: actions/setup-ruby@v1
- uses: actions/download-artifact@v1
with:
@ -61,7 +61,7 @@ jobs:
name: Build Linux Packages
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- uses: actions/checkout@v1
- uses: actions/setup-ruby@v1
- run: gem install packagecloud-ruby
- run: git clone https://github.com/git-lfs/build-dockers.git "$HOME/build-dockers"

@ -324,7 +324,14 @@ func (c *Configuration) HookDir() (string, error) {
if git.IsGitVersionAtLeast("2.9.0") {
hp, ok := c.Git.Get("core.hooksPath")
if ok {
return tools.ExpandPath(hp, false)
path, err := tools.ExpandPath(hp, false)
if err != nil {
return "", err
}
if filepath.IsAbs(path) {
return path, nil
}
return filepath.Join(c.LocalWorkingDir(), path), nil
}
}
return filepath.Join(c.LocalGitStorageDir(), "hooks"), nil

@ -12,6 +12,7 @@ import (
"io/ioutil"
"net/url"
"os"
"os/exec"
"path/filepath"
"regexp"
"strconv"
@ -604,6 +605,13 @@ func GitAndRootDirs() (string, string, error) {
out, err := cmd.Output()
output := string(out)
if err != nil {
// If we got a fatal error, it's possible we're on a newer
// (2.24+) Git and we're not in a worktree, so fall back to just
// looking up the repo directory.
if e, ok := err.(*exec.ExitError); ok && e.ProcessState.ExitCode() == 128 {
absGitDir, err := GitDir()
return absGitDir, "", err
}
return "", "", fmt.Errorf("failed to call git rev-parse --git-dir --show-toplevel: %q", buf.String())
}

@ -18,7 +18,7 @@ Requires: ruby
a swift, liberal HTML parser with a fantastic library
%prep
%if 0%{?el6}
%if 0%{?el6}%{?el7}
%setup -q -c -T
%else
%setup -q -n %{gem_name}-%{version}

@ -20,7 +20,7 @@ BuildArch: noarch
Inspired by ctemplate, Mustache is a framework-agnostic way to render logic-free views. As ctemplates says, "It emphasizes separating logic from presentation: it is impossible to embed application logic in this template language. Think of Mustache as a replacement for your views. Instead of views consisting of ERB or HAML with random helpers and arbitrary logic, your views are broken into two parts: a Ruby class and an HTML template.
%prep
%if 0%{?el6}
%if 0%{?el6}%{?el7}
%setup -q -c -T
%else
%setup -q -n %{gem_name}-%{version}

@ -18,7 +18,7 @@ Requires: ruby > 1.9.2
Fast Implementation of Gruber's Markdown in C
%prep
%if 0%{?el6}
%if 0%{?el6}%{?el7}
%setup -q -c -T
%else
%setup -q -n %{gem_name}-%{version}

@ -23,7 +23,7 @@ BuildArch: noarch
Builds Manuals
%prep
%if 0%{?el6}
%if 0%{?el6}%{?el7}
%setup -q -c -T
%else
%setup -q -n %{gem_name}-%{version}

@ -19,6 +19,14 @@ assert_hooks() {
[ ! -e ".git/post-merge" ]
}
refute_hooks() {
local hooks_dir="$1"
[ ! -e "$hooks_dir/pre-push" ]
[ ! -e "$hooks_dir/post-checkout" ]
[ ! -e "$hooks_dir/post-commit" ]
[ ! -e "$hooks_dir/post-merge" ]
}
begin_test "install with supported core.hooksPath"
(
set -e
@ -39,6 +47,28 @@ begin_test "install with supported core.hooksPath"
)
end_test
begin_test "install with supported core.hooksPath in subdirectory"
(
set -e
repo_name="supported-custom-hooks-path-subdir"
git init "$repo_name"
cd "$repo_name"
hooks_dir="custom_hooks_dir"
mkdir subdir
git config --local core.hooksPath "$hooks_dir"
(cd subdir && git lfs install 2>&1 | tee install.log)
grep "Updated git hooks" subdir/install.log
assert_hooks "$hooks_dir"
refute_hooks "subdir/$hooks_dir"
)
end_test
begin_test "install with supported expandable core.hooksPath"
(
set -e

@ -442,7 +442,7 @@ func (q *TransferQueue) collectBatches() {
// don't process further batches. Abort the wait queue so that
// we don't deadlock waiting for objects to complete when they
// never will.
if err != nil {
if err != nil && !errors.IsRetriableError(err) {
q.wait.Abort()
break
}
@ -538,7 +538,7 @@ func (q *TransferQueue) enqueueAndCollectRetriesFor(batch batch) (batch, error)
}
}
return next, err
return next, errors.NewRetriableError(err)
}
}