|
43 | 43 |
|
44 | 44 | # Build for Ubuntu Linux
|
45 | 45 | build-linux:
|
| 46 | + name: Build gitconvex for linux |
46 | 47 | needs: gitconvex-test
|
47 | 48 | runs-on: ubuntu-latest
|
48 | 49 | steps:
|
@@ -98,13 +99,10 @@ jobs:
|
98 | 99 |
|
99 | 100 | # Build for MacOS
|
100 | 101 | build-macos:
|
| 102 | + name: Build gitconvex for MacOS |
101 | 103 | needs: gitconvex-test
|
102 | 104 | runs-on: macos-latest
|
103 | 105 | steps:
|
104 |
| - - name: Install brew |
105 |
| - run: | |
106 |
| - /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)" |
107 |
| -
|
108 | 106 | - name: Set up Go 1.x
|
109 | 107 | uses: actions/setup-go@v2
|
110 | 108 | with:
|
@@ -134,6 +132,7 @@ jobs:
|
134 | 132 |
|
135 | 133 | # Test Build for Windows
|
136 | 134 | build-windows:
|
| 135 | + name: Build gitconvex for Windows |
137 | 136 | needs: gitconvex-test
|
138 | 137 | runs-on: windows-latest
|
139 | 138 | defaults:
|
@@ -190,3 +189,42 @@ jobs:
|
190 | 189 | echo ${{ secrets.CLI_AUTH_KEY }} > auth.txt
|
191 | 190 | gh auth login --with-token < auth.txt
|
192 | 191 | gh release upload ${{ secrets.TARGET_RELEASE_CHANNEL }} ./dist/gitconvex-windows-v${{ secrets.TARGET_RELEASE_CHANNEL }}.zip --clobber
|
| 192 | +
|
| 193 | + # Build for Homebrew |
| 194 | + build-for-homebrew: |
| 195 | + name: Build gitconvex Homebrew Tap bundle |
| 196 | + needs: gitconvex-test |
| 197 | + runs-on: macos-latest |
| 198 | + steps: |
| 199 | + - name: Set up Go 1.x |
| 200 | + uses: actions/setup-go@v2 |
| 201 | + with: |
| 202 | + go-version: ^1.16 |
| 203 | + id: go |
| 204 | + |
| 205 | + - name: Check out code into the Go module directory |
| 206 | + uses: actions/checkout@v2 |
| 207 | + |
| 208 | + - name: Get dependencies |
| 209 | + run: | |
| 210 | + brew install libssh2 |
| 211 | + brew install libgit2 |
| 212 | + go get -v ./... |
| 213 | +
|
| 214 | + - name: Package gitconvex bundle |
| 215 | + run: | |
| 216 | + make build |
| 217 | + rm ./dist/gitconvex |
| 218 | +
|
| 219 | + - name: Pick only required content for the Homebrew Tap |
| 220 | + run: | |
| 221 | + mkdir brew |
| 222 | + cp -rp api/ git/ global/ graph/ tests/ utils/ go.mod go.sum gqlgen.yml LICENSE server.go dist/ ./brew/ |
| 223 | + cd brew |
| 224 | + tar -czf gitconvex-v${{ secrets.TARGET_RELEASE_CHANNEL }}-brew.tar.gz * |
| 225 | +
|
| 226 | + - name: Github CLI Release for MacOS |
| 227 | + run: | |
| 228 | + echo ${{ secrets.CLI_AUTH_KEY }} > auth.txt |
| 229 | + gh auth login --with-token < auth.txt |
| 230 | + gh release upload ${{ secrets.TARGET_RELEASE_CHANNEL }} ./brew/gitconvex-v${{ secrets.TARGET_RELEASE_CHANNEL }}-brew.tar.gz --clobber |
0 commit comments