Skip to content

Commit

Permalink
Setup sourcegraph for scala 2
Browse files Browse the repository at this point in the history
  • Loading branch information
ghostbuster91 committed Jan 31, 2022
1 parent 9b3e5db commit 859073b
Showing 1 changed file with 35 additions and 6 deletions.
41 changes: 35 additions & 6 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@ jobs:
- name: Checkout
uses: actions/checkout@v2
- name: Set up JDK 11
uses: actions/setup-java@v1
uses: coursier/setup-action@v1.1.2
with:
java-version: 11
jvm: adopt:11
- name: Cache sbt
uses: coursier/cache-action@v6
with:
Expand All @@ -36,20 +36,49 @@ jobs:
JAVA_OPTS: -Xmx4G
steps:
- name: Checkout
uses: actions/checkout@v2
uses: coursier/[email protected]
with:
fetch-depth: 0 # checkout tags so that dynver works properly (we need the version for MiMa)
- name: Set up JDK 11
uses: actions/setup-java@v1
with:
java-version: 11
jvm: adopt:11
- name: Cache sbt
uses: coursier/cache-action@v6
with:
extraKey: sbt-cache-${{ runner.os }}
- name: Check MiMa # disable for major releases
run: sbt -v core/mimaReportBinaryIssues

sourcegraph:
name: Upload index to sourcegraph
needs: [ci]
# run on external PRs, but not on internal PRs since those will be run by push to branch
if: github.event_name == 'push' || github.event.pull_request.head.repo.full_name != github.repository
runs-on: ubuntu-20.04
env:
JAVA_OPTS: -Xmx4G
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Set up JDK 11
uses: coursier/[email protected]
with:
jvm: adopt:11
apps: lsif-java
- name: Cache sbt
uses: coursier/cache-action@v6
with:
extraKey: sbt-cache-${{ runner.os }}
- name: Generate LSIF
run: lsif-java index
- name: Upload LSIF data
uses: sourcegraph/lsif-upload-action@master
with:
endpoint: https://sourcegraph.com
github_token: ${{ secrets.GITHUB_TOKEN }}
file: dump.lsif

publish:
name: Publish release
needs: [ci]
Expand All @@ -61,9 +90,9 @@ jobs:
- name: Checkout
uses: actions/checkout@v2
- name: Set up JDK 11
uses: actions/setup-java@v1
uses: coursier/setup-action@v1.1.2
with:
java-version: 11
jvm: adopt:11
- name: Cache sbt
uses: coursier/cache-action@v6
with:
Expand Down

0 comments on commit 859073b

Please sign in to comment.