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

Operations redesign #3070

Draft
wants to merge 15 commits into
base: main
Choose a base branch
from
Draft

Operations redesign #3070

wants to merge 15 commits into from

Conversation

@mrixner
Copy link
Contributor

mrixner commented Dec 14, 2024

I notice you were planning to fix #1916 and #1023 with this PR; I was planning to do this same thing fairly soon (once I have more free time) using the new complex settings, allowing the backend functionality for #1824. My plan (which I realize now is mentioned almost exactly in #1023, but that's not where I got the inspiration...) was to have the operation history (instead of just a list of textual output) be a list of operation tile cards marked as install, update, remove, etc. with an expandable section including a button to view the package details, as well as the output logs and installation / update / etc options.

Another thing I was planning to add, partially related to this, was to give each package a last updated field (not the last updated field it currently has, which is the last time an update was published, but rather a field saying the last time it was updated on the user's computer) in the package details dialog.

I'm still willing to do this if you like, as well as of course redesign it to your liking, but if you plan to do it I hope you will take my suggestions into account.

----------------------------------------
| Update* Microsoft Edge** - winget  ^ |
----------------------------------------
| -Update Details-                     |
|  Package ID: Microsoft.Edge          |
|  Manager: winget                     |
|  Source: winget                      |
|  Time: 12/13/24 7:13 PM              |
|  Installation Options: (somehow)     |
|  Command: `winget [whatever] Edge`   |
|                                      |
|   {    View Package Details***   }   |
| ------------------------------------ |
| First line of output...              |
| Second line of output...             |
| Etcetera                             |
----------------------------------------
----------------------------------------
| Install* Microsoft Edge** - winget ⌄ |
----------------------------------------

*operation (update, install, remove, etc)
**using CoreTools.FormatAsName
***installed package details if install/update, otherwise the online package details

@marticliment
Copy link
Owner Author

If you want to implement this issues great, just wait until I get this PR merged, and then feel free to start whenever you want.

For the output format, I wouldn't show as much details about the package (since there is a window specifically designed for said thing), and my idea was to (taking advantage of the new complex settings) save a list of JSON objects, that can be easily serialized on data templates in WinUI, and then shown as custom controls. Perhaps buttons like "Package Details" could be added, to maintain functionality but not load the interface with too much content.

@marticliment marticliment mentioned this pull request Dec 20, 2024
4 tasks
@marticliment marticliment linked an issue Dec 20, 2024 that may be closed by this pull request
4 tasks
@mrixner
Copy link
Contributor

mrixner commented Dec 23, 2024

I had a thought - what if you used this operations redesign to also add in the custom input idea you had in #2925? This would allow vcpkg to easily change the triplet for the active (install) operation. I think if WSL is ever implemented it would be useful for distribution / package manager selection as well.

I was thinking you could either have a dropdown or text field (depending on the kind of input the operation needs; restricted or unrestricted) in the Line; if it has an input, the input can take up half the Line while the status takes up the other half, on either the left or the right. If it doesn't, the Line would just be entirely the status.

What do you think?

(Correction: #2146; mentioned in the issue, not the PR)

Perhaps it would be useful (looking into adding more package managers in the future) to add some kind of generic API to request the user for a choice/data input just before an installation operation begins, what do you think? Could this solve more adequately this issue while providing a non-vcpkg-unique solution?

I am planning on improvements on how operations in general work (for UI detachment), so it will be a great time for me to implement those generic questions/dialogs called from pacmans. However, I can't give an ETA on this, so on this second phase i'd let you know about it, so we can get this properly fixed

@marticliment
Copy link
Owner Author

Yes, this is definitely the time to add such feature. I will do it here

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment