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

Check if updates are available without updating #2582

Closed
fonsp opened this issue Jun 1, 2021 · 3 comments
Closed

Check if updates are available without updating #2582

fonsp opened this issue Jun 1, 2021 · 3 comments

Comments

@fonsp
Copy link
Member

fonsp commented Jun 1, 2021

For fonsp/Pluto.jl#844, I would like to check whether updates are available and conditionally show an "update" button to the user.

Currently, my ideas for implementing this are:

  1. Use the registry to find the latest version of direct dependencies, and compare to installed versions.
  2. Make a temporary copy of the environment folder, and call Pkg.update on it.

Both have shortcomings: 1. does not respect compatibility bounds between direct dependencies: updating to the latest version might not be possible. 2. can take a long time, downloading code and jll binaries.

Any suggestions? My suggestion would be a "dry run" option to API calls like update that just update a manifest without downloading source or binaries. This would enable 2.

@fonsp
Copy link
Member Author

fonsp commented Jun 1, 2021

Similarly, I would like to tell a user which version of Example will be installed, if it were added to the current environment.

I currently use 1. from above to achieve this, but 2. would be better, with the same shortcoming and proposed solution.

@KristofferC
Copy link
Sponsor Member

We had a dry run command #1367.

It was a bit tricky to define "dry" though because, for example, if you have packages that are added via git you need to update the git repository of those packages to know what the end result will be.

@KristofferC
Copy link
Sponsor Member

Dup of #1937

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

No branches or pull requests

2 participants