Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Setup sourcegraph for scala 3 #369

Open
wants to merge 4 commits into
base: scala3
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
41 changes: 35 additions & 6 deletions .github/workflows/ci.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 @@ -40,16 +40,45 @@ jobs:
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
uses: coursier/setup-action@v1.1.2
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 core3/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 @@ -62,9 +91,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
7 changes: 7 additions & 0 deletions build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -80,3 +80,10 @@ lazy val test = (projectMatrix in file(".test"))
)
.jvmPlatform(scalaVersions = List(scala3))
.jsPlatform(scalaVersions = List(scala3))

inThisBuild(
List(
semanticdbEnabled := true,
semanticdbVersion := "4.4.33"
)
)