diff --git a/.github/workflows/scip.yml b/.github/workflows/scip.yml new file mode 100644 index 00000000..8f1b8828 --- /dev/null +++ b/.github/workflows/scip.yml @@ -0,0 +1,26 @@ +name: 'Upload SCIP to Sourcegraph' +on: + push: + branches: + - main + pull_request: +jobs: + test: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - run: yarn install + - run: yarn global add ts-node @sourcegraph/src + - run: ts-node src/main.ts index + + - name: Upload SCIP to Cloud + run: src code-intel upload -github-token='${{ secrets.GITHUB_TOKEN }}' -no-progress + env: + SRC_ENDPOINT: https://sourcegraph.com/ + SRC_ACCESS_TOKEN: ${{ secrets.SRC_ACCESS_TOKEN_DOTCOM }} + + - name: Upload SCIP to S2 + run: src code-intel upload -github-token='${{ secrets.GITHUB_TOKEN }}' -no-progress + env: + SRC_ENDPOINT: https://sourcegraph.sourcegraph.com/ + SRC_ACCESS_TOKEN: ${{ secrets.SRC_ACCESS_TOKEN_S2 }} diff --git a/.github/workflows/sourcegraph.yml b/.github/workflows/sourcegraph.yml deleted file mode 100644 index f9d6ce9c..00000000 --- a/.github/workflows/sourcegraph.yml +++ /dev/null @@ -1,17 +0,0 @@ -name: Sourcegraph -on: - push: - branches: - - main - pull_request: -jobs: - test: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - - run: yarn install - - run: yarn global add ts-node @sourcegraph/src - - run: ts-node src/main.ts index - - run: src code-intel upload "-commit=${GITHUB_SHA}" "-github-token=${GITHUB_TOKEN}" - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}