fork of go-git with some jj specific features
at main 59 lines 1.3 kB view raw
1name: Git Compatibility 2on: 3 push: 4 branches: 5 - releases/v5.x 6 - main 7 pull_request: 8 9permissions: {} 10 11jobs: 12 test: 13 strategy: 14 fail-fast: false 15 matrix: 16 git: [[master, ubuntu-latest], [v2.11.0, ubuntu-latest]] 17 18 runs-on: ${{ matrix.git[1] }} 19 env: 20 GIT_VERSION: ${{ matrix.git[0] }} 21 GIT_DIST_PATH: .git-dist/${{ matrix.git[0] }} 22 23 permissions: 24 contents: read 25 26 steps: 27 - name: Checkout code 28 uses: actions/checkout@v4 29 30 - name: Install Go 31 uses: actions/setup-go@v5 32 with: 33 go-version: stable 34 35 - name: Install build dependencies 36 run: sudo apt-get update && sudo apt-get install gettext libcurl4-openssl-dev 37 38 - name: Git Build 39 run: make build-git 40 41 - name: Set Git config 42 run: | 43 export GIT_DIST_PATH=.git-dist/${{ matrix.git[0] }} 44 export GIT_EXEC_PATH=${{ github.workspace }}/$GIT_DIST_PATH 45 export PATH=$GIT_EXEC_PATH:$PATH 46 git --exec-path 47 git config --global user.email "gha@example.com" 48 git config --global user.name "GitHub Actions" 49 50 - name: Test 51 run: make test-coverage 52 53 - name: Test SHA256 54 run: make test-sha256 55 56 - name: Build go-git with CGO disabled 57 run: go build ./... 58 env: 59 CGO_ENABLED: 0