|
6 | 6 | branches: [ "main" ]
|
7 | 7 | pull_request:
|
8 | 8 | branches: [ "main" ]
|
| 9 | + schedule: |
| 10 | + - cron: '0 0 1 * *' |
9 | 11 |
|
10 | 12 | # Allows you to run this workflow manually from the Actions tab
|
11 | 13 | workflow_dispatch:
|
12 |
| - |
| 14 | + inputs: |
| 15 | + debug: |
| 16 | + description: 'Enable debug mode' |
| 17 | + type: boolean |
| 18 | + required: false |
| 19 | + default: false |
| 20 | + verbose: |
| 21 | + description: 'Enable verbose output' |
| 22 | + type: boolean |
| 23 | + required: false |
| 24 | + default: true |
| 25 | + |
13 | 26 | jobs:
|
14 | 27 | test-git-native:
|
15 | 28 | runs-on: ubuntu-latest
|
16 | 29 |
|
17 | 30 | steps:
|
18 | 31 | - name: Checkout code
|
19 |
| - uses: actions/checkout@v2 |
| 32 | + uses: actions/checkout@v4 |
20 | 33 |
|
21 | 34 | - name: Run tests git-native
|
22 | 35 | run: |
|
23 | 36 | git config --global user.email "[email protected]"
|
24 | 37 | git config --global user.name "Git Artifact"
|
25 | 38 | git --version
|
26 |
| - verbose=true bash _tests.sh || { |
27 |
| - exit_code=$? |
28 |
| - find . -name run.log |
29 |
| - find . -name run.log | xargs -I % cat % |
30 |
| - exit $exit_code |
31 |
| - } |
| 39 | + verbose=true bash _tests.sh |
| 40 | + |
32 | 41 | test-git-alpine-latest:
|
33 | 42 | runs-on: ubuntu-latest
|
34 | 43 | steps:
|
35 | 44 | - name: Checkout code
|
36 |
| - uses: actions/checkout@v2 |
| 45 | + uses: actions/checkout@v4 |
37 | 46 | - name: Run tests
|
38 | 47 | run: |
|
39 | 48 | set -eux
|
40 | 49 | git_version=latest
|
41 |
| - docker build --build-arg ALPINE_GIT_DOCKER_VERSION=${git_version} -t git-artifact:latest . |
42 |
| - docker run --rm -e debug=${debug:-false} -e verbose=true -v $(pwd):/git -v $HOME/.ssh:/root/.ssh git-artifact:latest --version |
43 |
| - docker run --rm -e debug=${debug:-false} -e verbose=true -v $(pwd):/git -v $HOME/.ssh:/root/.ssh git-artifact:latest artifact-tests || { |
44 |
| - exit_code=$? |
45 |
| - find . -name run.log |
46 |
| - find . -name run.log | xargs -I % cat % |
47 |
| - exit $exit_code |
48 |
| - } |
49 |
| - |
50 |
| - test-git-alpine-v2-36-2: |
| 50 | + docker build --build-arg ALPINE_GIT_DOCKER_VERSION="${git_version}" --build-arg USER_ID="$(id -u)" --build-arg GROUP_ID="$(id -g)" -t "git-artifact:${git_version}" . |
| 51 | + docker run --rm -u "$(id -u):$(id -g)" -e debug="${{ github.event.inputs.debug}}" -e verbose="${{ github.event.inputs.verbose}}" -v "$(pwd):/git" -v "$HOME/.ssh:/root/.ssh" "git-artifact:latest" --version |
| 52 | + docker run --rm -u "$(id -u):$(id -g)" -e debug="${{ github.event.inputs.debug}}" -e verbose="${{ github.event.inputs.verbose}}" -v "$(pwd):/git" -v "$HOME/.ssh:/root/.ssh" "git-artifact:latest" artifact-tests |
| 53 | +
|
| 54 | + test-git-alpine-v2-49-0: |
| 55 | + runs-on: ubuntu-latest |
| 56 | + steps: |
| 57 | + - name: Checkout code |
| 58 | + uses: actions/checkout@v4 |
| 59 | + - name: Run tests |
| 60 | + run: | |
| 61 | + set -eux |
| 62 | + git_version=v2.49.0 |
| 63 | + docker build --build-arg ALPINE_GIT_DOCKER_VERSION="${git_version}" --build-arg USER_ID="$(id -u)" --build-arg GROUP_ID="$(id -g)" -t "git-artifact:${git_version}" . |
| 64 | + docker run --rm -u "$(id -u):$(id -g)" -e debug="${{ github.event.inputs.debug}}" -e verbose="${{ github.event.inputs.verbose}}" -v "$(pwd):/git" -v "$HOME/.ssh:/root/.ssh" "git-artifact:${git_version}" --version |
| 65 | + docker run --rm -u "$(id -u):$(id -g)" -e debug="${{ github.event.inputs.debug}}" -e verbose="${{ github.event.inputs.verbose}}" -v "$(pwd):/git" -v "$HOME/.ssh:/root/.ssh" "git-artifact:${git_version}" artifact-tests |
| 66 | +
|
| 67 | + |
| 68 | + test-git-alpine-v2-47-2: |
| 69 | + runs-on: ubuntu-latest |
| 70 | + steps: |
| 71 | + - name: Checkout code |
| 72 | + uses: actions/checkout@v4 |
| 73 | + - name: Run tests |
| 74 | + run: | |
| 75 | + set -eux |
| 76 | + git_version=v2.47.2 |
| 77 | + docker build --build-arg ALPINE_GIT_DOCKER_VERSION="${git_version}" --build-arg USER_ID="$(id -u)" --build-arg GROUP_ID="$(id -g)" -t "git-artifact:${git_version}" . |
| 78 | + docker run --rm -u "$(id -u):$(id -g)" -e debug="${{ github.event.inputs.debug}}" -e verbose="${{ github.event.inputs.verbose}}" -v "$(pwd):/git" -v "$HOME/.ssh:/root/.ssh" "git-artifact:${git_version}" --version |
| 79 | + docker run --rm -u "$(id -u):$(id -g)" -e debug="${{ github.event.inputs.debug}}" -e verbose="${{ github.event.inputs.verbose}}" -v "$(pwd):/git" -v "$HOME/.ssh:/root/.ssh" "git-artifact:${git_version}" artifact-tests |
| 80 | +
|
| 81 | + test-git-alpine-v2-36-2: |
51 | 82 | runs-on: ubuntu-latest
|
52 | 83 | steps:
|
53 | 84 | - name: Checkout code
|
54 |
| - uses: actions/checkout@v2 |
| 85 | + uses: actions/checkout@v4 |
55 | 86 | - name: Run tests
|
56 | 87 | run: |
|
57 | 88 | set -eux
|
58 | 89 | git_version=v2.36.2
|
59 |
| - docker build --build-arg ALPINE_GIT_DOCKER_VERSION=${git_version} -t git-artifact:${git_version} . |
60 |
| - docker run --rm -e debug=${debug:-false} -e verbose=true -v $(pwd):/git -v $HOME/.ssh:/root/.ssh git-artifact:${git_version} --version |
61 |
| - docker run --rm -e debug=${debug:-false} -e verbose=true -v $(pwd):/git -v $HOME/.ssh:/root/.ssh git-artifact:${git_version} artifact-tests || { |
62 |
| - exit_code=$? |
63 |
| - find . -name run.log |
64 |
| - find . -name run.log | xargs -I % cat % |
65 |
| - exit $exit_code |
66 |
| - } |
| 90 | + docker build --build-arg ALPINE_GIT_DOCKER_VERSION="${git_version}" --build-arg USER_ID="$(id -u)" --build-arg GROUP_ID="$(id -g)" -t "git-artifact:${git_version}" . |
| 91 | + docker run --rm -u "$(id -u):$(id -g)" -e debug="${{ github.event.inputs.debug}}" -e verbose="${{ github.event.inputs.verbose}}" -v "$(pwd):/git" -v "$HOME/.ssh:/root/.ssh" "git-artifact:${git_version}" --version |
| 92 | + docker run --rm -u "$(id -u):$(id -g)" -e debug="${{ github.event.inputs.debug}}" -e verbose="${{ github.event.inputs.verbose}}" -v "$(pwd):/git" -v "$HOME/.ssh:/root/.ssh" "git-artifact:${git_version}" artifact-tests |
67 | 93 |
|
68 | 94 | test-git-alpine-v2-26-2:
|
69 | 95 | runs-on: ubuntu-latest
|
70 | 96 | steps:
|
71 | 97 | - name: Checkout code
|
72 |
| - uses: actions/checkout@v2 |
| 98 | + uses: actions/checkout@v4 |
73 | 99 | - name: Run tests
|
74 | 100 | run: |
|
75 | 101 | set -eux
|
76 | 102 | git_version=v2.26.2
|
77 |
| - docker build --build-arg ALPINE_GIT_DOCKER_VERSION=${git_version} -t git-artifact:${git_version} . |
78 |
| - docker run --rm -e debug=${debug:-false} -e verbose=true -v $(pwd):/git -v $HOME/.ssh:/root/.ssh git-artifact:${git_version} --version |
79 |
| - docker run --rm -e debug=${debug:-false} -e verbose=true -v $(pwd):/git -v $HOME/.ssh:/root/.ssh git-artifact:${git_version} artifact-tests || { |
80 |
| - exit_code=$? |
81 |
| - find . -name run.log |
82 |
| - find . -name run.log | xargs -I % cat % |
83 |
| - exit $exit_code |
84 |
| - } |
| 103 | + docker build --build-arg ALPINE_GIT_DOCKER_VERSION="${git_version}" --build-arg USER_ID="$(id -u)" --build-arg GROUP_ID="$(id -g)" -t "git-artifact:${git_version}" . |
| 104 | + docker run --rm -u "$(id -u):$(id -g)" -e debug="${{ github.event.inputs.debug}}" -e verbose="${{ github.event.inputs.verbose}}" -v "$(pwd):/git" -v "$HOME/.ssh:/root/.ssh" "git-artifact:${git_version}" --version |
| 105 | + docker run --rm -u "$(id -u):$(id -g)" -e debug="${{ github.event.inputs.debug}}" -e verbose="${{ github.event.inputs.verbose}}" -v "$(pwd):/git" -v "$HOME/.ssh:/root/.ssh" "git-artifact:${git_version}" artifact-tests |
0 commit comments