topgrade-rs / topgrade

Upgrade all the things
GNU General Public License v3.0
1.9k stars 124 forks source link

parallel update(everything)? #877

Open littleblack111 opened 1 month ago

littleblack111 commented 1 month ago

I want to suggest a new step

I want to suggest some general feature

Topgrade should make it so it can do ALL in parallel. it should spawn sub shells and do them in split screens/multiple screens

More information

add a option in config or add argument for it to be enabled.

niStee commented 1 month ago

Instead of using the GitHub issues page, you could consider posting your suggestion on the Topgrade discussions page at https://github.com/topgrade-rs/topgrade/discussions/categories/ideas. The discussions section is often a better place to share ideas and get feedback from the project maintainers and community.

SteveLauC commented 1 month ago

I have thought about this, we can technically spawn all the sub-processes in parallel, but when it comes to user input, all these processes share the same terminal (stdin), it would be totally chaos.

And Topgrade by the original design, is for interactive usage, when a step (tool) fails, it gives you a prompt so that you can take further actions, so I would say this parallel model is not suitable for Topgrade, or it would require a huge refactor that is not worthwhile.

littleblack111 commented 1 month ago

I have thought about this, we can technically spawn all the sub-processes in parallel, but when it comes to user input, all these processes share the same terminal (stdin), it would be totally chaos.

And Topgrade by the original design, is for interactive usage, when a step (tool) fails, it gives you a prompt so that you can take further actions, so I would say this parallel model is not suitable for Topgrade, or it would require a huge refactor that is not worthwhile.

Maybe focus on one window. And use mouse or sth to control it. Kinda like tmux

SteveLauC commented 1 month ago

Maybe focus on one window. And use mouse or sth to control it. Kinda like tmux

You mean scattering the subprocesses across multiple tmux windows, this is indeed something theorically Topgrade can do.

Though I guess the UX will be bad, personally I have more than 10 steps to run in Topgrade, which means I need to repeatedly check the status of those steps to ensure they won't go wrong🤔