Closed Genora51 closed 2 months ago
Currently we don't have such a command.
If resolved packages already exist in the cache they will not be redownloaded.
(well we have something but perhaps not really what you need... https://github.com/dart-lang/pub/blob/19570012d2fc54a18731c83d3c25728fe67d4575/bin/dependency_services.dart is the backing of our dependabot support - it attempts to do updates without downloading packages the tool is described here: https://github.com/dependabot/dependabot-core/blob/7bedcef466a42651f80f5b1a001e45353f4dd38f/pub/README.md You cannot access it directly from the dart sdk - but need to add a git dependency on dartlang-pub... again probably not what you want... )
What is your tool trying to do?
dependency_services
seems like exactly what I'm looking for! Only problem: on the latest version pub:dependency_services report
seems to hang? Or is it just always quite slow and I'm just not letting it run long enough?
Only problem: on the latest version pub:dependency_services report seems to hang?
It is waiting for input on stdin. run it like
echo '{}' | dart run pub:dependency_services report
Or if you want to limit the report to a single package run:
echo '{target:"<pgk>"}' | dart run pub:dependency_services report
Is this working - do we need more here?
Yes it did the trick! Thanks
I'm working on an internal tool which updates
pubspec.yaml
and then needs to updatepubspec.lock
. Is there a way to perform this update without fetching hundreds of megabytes of files to disk? That is, is there a way to runpub get
to skip the cache and only update the lockfile?If not, it would be a great feature to have in
pub
.