Repository navigation
60 lines (57 loc) · 2.02 KB
/
Copy pathgit-cli.yml
File metadata and controls
60 lines (57 loc) · 2.02 KB
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
49
50
51
52
53
54
55
56
57
58
59
60
name: Minimum Git CLI
on:
push:
branches: [main]
pull_request:
workflow_dispatch:
permissions:
contents: read
jobs:
git-2-52:
runs-on: ubuntu-latest
env:
GIT_PYTHON_BACKEND: cli
steps:
- uses: actions/checkout@v7
- uses: actions/checkout@v7
with:
repository: git/git
ref: v2.52.0
path: .git-source
- uses: actions/setup-python@v7
with:
python-version: '3.12'
- name: Build minimum supported Git
working-directory: .git-source
run: |
make -j2 prefix="$RUNNER_TEMP/git" NO_GETTEXT=YesPlease NO_TCLTK=YesPlease NO_PERL=YesPlease NO_CURL=YesPlease install
echo "$RUNNER_TEMP/git/bin" >> "$GITHUB_PATH"
- name: Prepare Rust for fixture tooling
run: |
rustup update stable
rustup default stable
echo "CARGO_TARGET_DIR=$RUNNER_TEMP/gix-target" >> "$GITHUB_ENV"
- name: Cache GixPython builds
uses: actions/cache@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0
with:
path: |
~/.cargo/registry
~/.cargo/git
${{ runner.temp }}/gix-target
~/.cache/pip
key: minimum-git-gix-${{ runner.os }}-${{ hashFiles('gix-requirements.txt') }}
- name: Install GitPython and test dependencies
run: |
python -m pip install ./smmap ./gitdb '.[test]'
python -c 'from gix import testtools'
- name: Verify native format and safety contracts
env:
GIT_CONFIG_NOSYSTEM: '1'
GIT_CONFIG_GLOBAL: /dev/null
GIT_AUTHOR_NAME: GitPython Tests
GIT_AUTHOR_EMAIL: tests@example.invalid
GIT_COMMITTER_NAME: GitPython Tests
GIT_COMMITTER_EMAIL: tests@example.invalid
run: |
git version
python -m pytest --no-cov --tb=short test/test_cli_objects_index.py test/test_cli_safety.py test/test_reflog.py test/test_config.py test/test_remote_cli.py test/test_submodule.py::test_submodule_cli_lifecycle