-
-
Notifications
You must be signed in to change notification settings - Fork 410
Auto-update dependencies: output info in machine-readable format #758
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
Conversation
856d62b
to
2215d22
Compare
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.
Great idea.
Could you please rebase your branch on latest master, which contains a fix for the failed travis-ci tests.
I added two comments with questions.
scalalib/src/dependency/versions/ModuleDependenciesVersions.scala
Outdated
Show resolved
Hide resolved
This avoids exposing non-serializable data structures.
This makes it easy to build other tasks that depend on the output of dependency updates
2215d22
to
8e6bf2d
Compare
@lefou, I addressed your comments |
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.
Looks good to me. I'd like to have some documentation for the new command. See below.
@@ -18,6 +18,10 @@ object Dependency extends ExternalModule { | |||
allowPreRelease) | |||
} | |||
|
|||
def showUpdates(ev: Evaluator, allowPreRelease: Boolean = false) = T.command{ |
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.
Can you please add some ScalaDoc to the new command. It would be great, if you could also update/add the comment of the changed updates
command.
Thank you! |
Mill has a convenient task to check for the availability of newer versions of dependencies
mill.scalalib.Dependency/updates
.Unfortunately this task only prints the output (in human readable form), but does not persist it in a machine-readable format. This makes it very difficult to reuse the output in other tasks, essentially requiring regex parsing of strings.
The changes proposed here change the
updates
task to expose the underlying data structures representing the upgrade path. An additional task,showUpdates
is added, implementing the original, human readable, output of updates.