aboutsummaryrefslogtreecommitdiff
path: root/.github/workflows/scip.yml
blob: 0310cfb761295282e081d278ddce96dff520e42e (plain)
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
name: SCIP
on:
  push:
    paths:
      - '**.go'
      - 'go.mod'
      - '.github/workflows/scip.yml'
env:
  GOPROXY: "https://proxy.golang.org"

jobs:
  scip-go:
    if: github.repository == 'gogs/gogs'
    runs-on: ubuntu-latest
    container: sourcegraph/scip-go
    steps:
      - name: Checkout
        uses: actions/checkout@v3
      - name: Set directory to safe for git
        run: git config --global --add safe.directory $GITHUB_WORKSPACE
      - name: Get src-cli
        run: |
          curl -L https://sourcegraph.com/.api/src-cli/src_linux_amd64 -o /usr/local/bin/src
          chmod +x /usr/local/bin/src
      - name: Generate SCIP data
        run: scip-go --no-animation
      - name: Upload SCIP data to sourcegraph.com
        run: src code-intel upload -github-token='${{ secrets.GITHUB_TOKEN }}' -no-progress -repo=github.com/gogs/gogs
        env:
          SRC_ENDPOINT: https://sourcegraph.com/
      - name: Upload SCIP data to S2
        run: src code-intel upload -github-token='${{ secrets.GITHUB_TOKEN }}' -no-progress -repo=github.com/gogs/gogs
        env:
          SRC_ENDPOINT: https://sourcegraph.sourcegraph.com/
      - name: Upload SCIP data to cs.unknwon.dev
        run: src code-intel upload -github-token='${{ secrets.GITHUB_TOKEN }}' -no-progress -repo=github.com/gogs/gogs
        env:
          SRC_ENDPOINT: https://cs.unknwon.dev/