forked from git-lfs/git-lfs
-
Notifications
You must be signed in to change notification settings - Fork 2
48 lines (47 loc) · 1.55 KB
/
ci.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
name: CI
on: [push, pull_request]
env:
GOTOOLCHAIN: local
jobs:
build-latest:
name: Build with latest Git
strategy:
matrix:
os: [ubuntu-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
persist-credentials: false
- run: git fetch origin "+${GITHUB_REF}:${GITHUB_REF}"
if: ${{ github.ref_type == 'tag' }}
- run: git clone -b master https://github.com/git/git.git "$HOME/git"
- run: |
echo "GIT_INSTALL_DIR=$HOME/git" >> "$GITHUB_ENV"
echo "$HOME/git/bin" >> "$GITHUB_PATH"
if: ${{ matrix.os == 'macos-latest' }}
# We install our custom Git version into a PATH location ahead of
# that of the Git installed by Homebrew.
- run: script/build-git "$HOME/git"
build-earliest:
name: Build with earliest Git
strategy:
matrix:
os: [ubuntu-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
persist-credentials: false
- run: git fetch origin "+${GITHUB_REF}:${GITHUB_REF}"
if: ${{ github.ref_type == 'tag' }}
- run: git clone -b v2.0.0 https://github.com/git/git.git "$HOME/git"
- run: |
echo "GIT_INSTALL_DIR=$HOME/git" >> "$GITHUB_ENV"
echo "$HOME/git/bin" >> "$GITHUB_PATH"
if: ${{ matrix.os == 'macos-latest' }}
# We install our custom Git version into a PATH location ahead of
# that of the Git installed by Homebrew.
- run: script/build-git "$HOME/git"