-
Notifications
You must be signed in to change notification settings - Fork 216
Fix #2678: Handle projects with only resources #2692
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
Merged
Merged
Changes from 4 commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
106cb90
bloop does not see a dependent project that contains only resources
3991fcb
enable all compile tests
6e6afe2
reformat code
bde7702
small update
928eab7
Update frontend/src/test/scala/bloop/BaseCompileSpec.scala
wiacekm 521b82b
remove TODO
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
10 changes: 10 additions & 0 deletions
10
frontend/src/test/resources/resources-only-downstream-project/build.sbt
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,10 @@ | ||
| Global / bloopConfigDir := baseDirectory.value / "bloop-config" | ||
|
|
||
| ThisBuild / scalaVersion := "3.5.0" | ||
|
|
||
| lazy val projectA = project.in(file("project-a")) | ||
| lazy val projectAj = project.in(file("project-aj")) | ||
|
|
||
| lazy val projectB = project | ||
| .in(file("project-b")) | ||
| .dependsOn(projectA, projectAj) |
1 change: 1 addition & 0 deletions
1
...rc/test/resources/resources-only-downstream-project/project-a/src/main/resources/test.txt
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| text |
5 changes: 5 additions & 0 deletions
5
...d/src/test/resources/resources-only-downstream-project/project-aj/src/main/java/Main.java
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,5 @@ | ||
| public class Main { | ||
| public static void main(String[] args) { | ||
| System.out.println("Hello, world!"); | ||
| } | ||
| } |
1 change: 1 addition & 0 deletions
1
.../test/resources/resources-only-downstream-project/project-aj/src/main/resources/test2.txt
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| text |
10 changes: 10 additions & 0 deletions
10
.../src/test/resources/resources-only-downstream-project/project-b/src/main/scala/Main.scala
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,10 @@ | ||
| import scala.io.Source | ||
|
|
||
| object Main { | ||
| def main(args: Array[String]): Unit = { | ||
| val text = Source.fromResource("test.txt").getLines().mkString | ||
| println(text) | ||
| val text2 = Source.fromResource("test2.txt").getLines().mkString | ||
| println(text2) | ||
| } | ||
| } |
1 change: 1 addition & 0 deletions
1
frontend/src/test/resources/resources-only-downstream-project/project/build.properties
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| sbt.version=1.11.0 |
8 changes: 8 additions & 0 deletions
8
frontend/src/test/resources/resources-only-downstream-project/project/plugins.sbt
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,8 @@ | ||
| val pluginVersion = sys.props.getOrElse( | ||
| "bloopVersion", | ||
| throw new RuntimeException("Unable to find -DbloopVersion") | ||
| ) | ||
|
|
||
| addSbtPlugin("ch.epfl.scala" % "sbt-bloop" % pluginVersion) | ||
|
|
||
| updateOptions := updateOptions.value.withLatestSnapshots(false) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think we have anything that we don't want to copy, this is usually useful for invalidated sources. It's safe to set it to empty for this use case
I wonder if we should delete anything no longer available, but that might be a separate thing altogether.