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

Handle cross-build projects #13

Open
stringbean opened this issue Feb 13, 2020 · 1 comment
Open

Handle cross-build projects #13

stringbean opened this issue Feb 13, 2020 · 1 comment
Labels
enhancement New feature or request
Milestone

Comments

@stringbean
Copy link
Owner

At the moment only libraries for the current Scala version are considered when checking dependencies.
This leads to an issue where running dependencyLockCheck will fail if you switch current versions.

Having a lock file for each Scala version would probably be the easiest solution (eg build.sbt_2.11.lock or build_2.11.sbt.lock).

@stringbean stringbean added the enhancement New feature or request label Feb 13, 2020
@stringbean stringbean added this to the v3 milestone Feb 13, 2020
colindean added a commit to target/data-validator that referenced this issue Apr 3, 2023
Caveats of this:

1. [Crossbuilds may not be supported][crossbuilds], impacting #84.
2. The hash used is SHA1, which is deprecated including by [NIST][nist].
   Some work is in draft PRs for introducing a new version of the
   lockfile that may enable SHA256 or other hash algorithms.

Fixes #129

[crossbuilds]: stringbean/sbt-dependency-lock#13
[nist]: https://www.nist.gov/news-events/news/2022/12/nist-retires-sha-1-cryptographic-algorithm
@dmivankov
Copy link

It is currently possible to create lock file per version with something like

dependencyLockFile := { baseDirectory.value / s"build.scala-${CrossVersion.partialVersion(scalaVersion.value) match { case Some((2, n)) => s"2.$n" }}.sbt.lock" },

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants