• Stars
    star
    133
  • Rank 267,972 (Top 6 %)
  • Language
    Scala
  • License
    Apache License 2.0
  • Created almost 5 years ago
  • Updated 11 months ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

An sbt plugin for missinglink

sbt-missinglink

An sbt plugin for missinglink.

Usage

Add the following lines in project/plugins.sbt:

addSbtPlugin("ch.epfl.scala" % "sbt-missinglink" % "<sbt-missinglink-version>")
libraryDependencies += "com.spotify" % "missinglink-core" % "<missinglink-core-version>"

You can find the latest missinglink-core version in their release list.

sbt-missinglink missinglink-core
sbt-missinglink badge missinglink-core badge

Then, run the following task for the project you want to test:

> theProject/missinglinkCheck

This will check that the transitive dependencies of your project do not exhibit any binary compatibility conflict, assuming that the methods of your Compile configuration (in src/main/) are all called.

Testing another configuration

You can test another configuration, such as Test or Runtime, with:

> theProject/Runtime/missinglinkCheck

Do not fail on conflicts

By default, the plugin fails the build if any conflicts are found. It can be disabled by the missinglinkFailOnConflicts setting:

missinglinkFailOnConflicts := false

Ignore conflicts in certain packages

Conflicts can be ignored based on the package name of the class that has the conflict. There are separate configuration options for ignoring conflicts on the "source" side of the conflict and the "destination" side of the conflict. Packages on the source side can be ignored with missinglinkIgnoreSourcePackages and packages on the destination side can be ignored with missinglinkIgnoreDestinationPackages:

missinglinkIgnoreDestinationPackages += IgnoredPackage("com.google.common")
missinglinkIgnoreSourcePackages += IgnoredPackage("com.example")

By default, all subpackages of the specified package are also ignored, but this can be disabled by the ignoreSubpackages field: IgnoredPackage("test", ignoreSubpackages = false).

Excluding some dependencies from the analysis

You can exclude certain dependencies using moduleFilter:

missinglinkExcludedDependencies += moduleFilter(organization = "com.google.guava")
missinglinkExcludedDependencies += moduleFilter(organization = "ch.qos.logback", name = "logback-core")

Limiting the concurrency

sbt runs the missing-link analysis on the modules you have concurrently. Analysis of each module can take up a considerable amount of memory, so you might want to limit the degree of concurrency. To run missing-link at most on 4 projects at a time, add this setting to your project root.

concurrentRestrictions += Tags.limit(missinglinkConflictsTag, 4)

More information

You can find more information about the problem statement, caveats and limitations, etc. in the upstream project missinglink.

Acknowledgments

Scala Center

This project is funded by the Scala Center.

More Repositories

1

bloop

Bloop is a build server and CLI tool to compile, test and run Scala fast from any editor or build tool.
Scala
880
star
2

scalafix

Refactoring and linting tool for Scala
Scala
812
star
3

scastie

An interactive playground for Scala
Scala
427
star
4

scala-3-migration-guide

The Scala 3 migration guide for everyone.
Scala
237
star
5

scalajs-bundler

Scala
232
star
6

scaladex

The Scala Package Index
Scala
195
star
7

scalac-profiling

Compilation profiling tool for Scala 2 projects
Scala
127
star
8

macros

Archived - Scala Macros
Scala
123
star
9

sprees

Scala Open Source Sprees: join us and learn how to contribute to open source!
110
star
10

advisoryboard

Scala Center Advisory Board planning
Scala
101
star
11

scala3-migrate

A tool to help migrating from Scala 2 to Scala 3
Scala
101
star
12

sbt-scalafix

sbt plugin for Scalafix
Scala
83
star
13

sbt-version-policy

Compatibility checks for your dependencies
Scala
80
star
14

sbt-dependency-submission

A Github Action to submit the dependency graph of an sbt build to the Dependency Submission API
Scala
58
star
15

scala-debug-adapter

Implementation of the Debug Adapter Protocol for Scala
Scala
56
star
16

scala-advent-of-code

Scala Center's solution of Advent of Code
Scala
53
star
17

tasty-query

Scala
46
star
18

GoogleSummerOfCode

Ideas list for GSoC 2024 mentored by Scala Center
37
star
19

classpath-shrinker

Scalac plugin to detect classpath entries that aren't directly used
Scala
28
star
20

course-management-tools

Course Management tools
Scala
27
star
21

sbtfix

Scalafix rewrites to migrate from sbt 0.13 to 1.0.
Scala
23
star
22

tooling-working-groups

Scala Tooling Working Groups
20
star
23

sbt-eviction-rules

An sbt plugin enhancing the evicted key.
Scala
19
star
24

scala-syntax

Scalameta pretty printer for better Scalafix refactorings
Scala
17
star
25

mix-macros-scala-2-and-3

Demo mixing definitions of macros for Scala 2 and 3 in one source file
Scala
17
star
26

GoogleSummerOfCode2021

16
star
27

simple-rockets-compiler

A Scala 3 DSL to compile programs for SimpleRockets 2
Scala
11
star
28

scalafix.g8

Giter8 template to implement custom rewrites
Scala
10
star
29

tasty-mima

TASTy Migration Manager
Scala
9
star
30

load-plugin

A sbt helper to programmatically load plugins
Scala
9
star
31

scaladex-contrib

pom => github
8
star
32

student-projects

The list of the available projects at the Scala Center for bachelor and master students.
8
star
33

tasty-reader-compat-testkit

Validating the TASTy Reader for Scala 2 with external projects that are published for Scala 3
Scala
8
star
34

accessible-scala

SCP-016: Accessible Scala
Scala
7
star
35

gradle-bloop

Gradle plugin for Bloop
Scala
6
star
36

effective-scala-slide-code

Scala
6
star
37

platform

The Scala Platform process and the tools around it.
Scala
6
star
38

library-example

Scala
6
star
39

ambassadors

This repo contains the materials for the Scala Center ambassadors to be used in their activities
5
star
40

sbt-tasty-mima

sbt plugin for TASTy-MiMa
Scala
4
star
41

sbt-scalafix-example

Example sbt build using scalafix
Scala
4
star
42

example-scalafix-rule

Scala
3
star
43

scaladex-index

bintray search meta, bintray poms, sonatype poms, users poms, live data
3
star
44

scalafix-named-literal-arguments

Example Scalafix rule to insert named arguments for boolean literals. This repo only exists for documentation purposes. The rule itself is not intended to be used
Scala
3
star
45

homebrew-bloop

Homebrew formula for Bloop
Ruby
2
star
46

bloop-maven-plugin

Maven Plugin for Bloop
Scala
2
star
47

versions

Scala
2
star
48

scala3-migration-course

A Scala 3 migration course based on sbt-scala3-migrate
Scala
1
star
49

sbt-github-dependency-graph

An sbt plugin to submit your dependencies to the Github Dependency Graph API.
Scala
1
star
50

intellij-scala-quickinstall

EXPERIMENT - Single-click install script for IntelliJ + Scala plugin
1
star
51

scaladex-small-index

1
star
52

accessible-scala-demo

CSS
1
star
53

scalacenter.github.io

HTML
1
star
54

bloop-config

Bloop configuration library
Scala
1
star
55

snake-workshop

Workshop for Scalabase 2021
Scala
1
star