Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Merge branch 'main' into wb/refactor-apply-proxy #6660

Merge branch 'main' into wb/refactor-apply-proxy

Merge branch 'main' into wb/refactor-apply-proxy #6660

Workflow file for this run

name: Go CI
on:
workflow_dispatch:
push:
env:
GOPRIVATE: "github.com/sourcegraph/*"
PRIVATE_TOKEN: "${{ secrets.PRIVATE_SG_ACCESS_TOKEN }}"
jobs:
go-test:
strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Get Go version from mise
id: mise
run: echo "go-version=$(grep 'golang' mise.toml | cut -d'"' -f2)" >> $GITHUB_OUTPUT
shell: bash
- name: Set up Go
uses: actions/setup-go@v6
with:
go-version: ${{ steps.mise.outputs.go-version }}
- name: (Windows) Enable pulling Go modules from private sourcegraph/sourcegraph
if: runner.os == 'Windows'
run: git config --global url."https://$env:PRIVATE_TOKEN@github.com/sourcegraph/".insteadOf "https://github.com/sourcegraph/"
- name: (Default) Enable pulling Go modules from private sourcegraph/sourcegraph
if: runner.os != 'Windows'
run: git config --global url."https://${PRIVATE_TOKEN}@github.com/sourcegraph/".insteadOf "https://github.com/sourcegraph/"
- run: |
go test -race -v ./...
go test -v ./...
# This job provides a stable name for branch protection rules
# It will only pass if all Go CI matrix tests above pass
go-test-complete:
runs-on: ubuntu-latest
needs: go-test
if: always()
steps:
- name: Check Go CI results
run: |
if [[ "${{ needs.go-test.result }}" != "success" ]]; then
echo "One or more Go CI tests failed"
exit 1
fi
echo "All Go CI tests passed"
Morty Proxy This is a proxified and sanitized view of the page, visit original site.