ecosyste-ms / ecosyste-ms/parser

Parse build.sbt and project/*.sbt

Open
#1,196 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Ruby
Stars
14
Forks
4
PR merge metrics
No merged PRs in 30d

Description

bibliothecary's maven parser matches `sbt-update-full.txt` (generated output) but not `build.sbt` itself, so pure-sbt Scala projects contribute no dependency data to repos.ecosyste.ms. In a 267-repo sample of GitHub `language=Scala` repositories, 14% had any parseable manifest and none via sbt.

sbt build files are Scala code so a full parse is out of reach, but a regex pass covers the common forms:

```
"org.typelevel" %% "cats-core" % "2.9.0"
"org.slf4j" % "slf4j-api" % "1.7.36"
addSbtPlugin("org.scalameta" % "sbt-scalafmt" % "2.5.2")
```

`%%` appends the Scala binary version to the artifactId at resolve time; recording the name unsuffixed (or with a marker) is fine since the ecosystem is still `maven`.

Files to match: `build.sbt`, `*.sbt` at the project root, `project/*.sbt`, `project/Dependencies.scala`.

The change is in `ecosyste-ms/bibliothecary` (`lib/bibliothecary/parsers/maven.rb`); filing here since that fork has issues disabled.

Contributor guide

Open the contributing guide

Research direction

Start at ecosyste-ms/bibliothecary/lib/bibliothecary/parsers/maven.rb and inspect how the existing parser handles manifest paths and dependency declarations. Cover build.sbt, root-level *.sbt, project/*.sbt, and project/Dependencies.scala, then verify that the shown %, %%, and addSbtPlugin forms produce Maven dependency data.

Written by the indexing model from the issue text.

Assessment

Tech stack
ruby, scala
Domain
build-system, tooling
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Active
Clarity
Clearly specified
Newbie friendliness
76/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.