Add a way to refresh build last failed module, then continue
I often get to such scenario:
$ kde-builder dolphin
...
... # building modules, install succeeded
...
Building kidletime from frameworks (40/60)
Fetching remote changes to kidletime
Merging kidletime changes from branch master
No changes to kidletime source code, but proceeding to build anyway.
Compiling... failed (after 3 seconds)
kidletime didn't build, stopping here.
Now I want to open another tab in terminal, and run:
$ kde-builder kidletime -r -D
...
<<< PACKAGES SUCCESSFULLY BUILT >>>
kidletime
Now I go to the original terminal tab and run:
$ kde-builder dolphin -a kidletime
But then again some module fails, and I need to repeat procedure again. It requires copy-erasing-pasting-erasing-pasting for each such case.
It would be good to support add some option to offer refresh building only for the last failed module, like kidletime in this example, but then continue as normal for the rest builds (i.e. not refresh building them).
One way of how I think it may work is with prompt:
$ kde-builder dolphin
...
... # building modules, install succeeded
...
Building kidletime from frameworks (40/60)
Fetching remote changes to kidletime
Merging kidletime changes from branch master
No changes to kidletime source code, but proceeding to build anyway.
Compiling... failed (after 3 seconds)
kidletime didn't build, stopping here.
Would you like to refresh build kidletime? [y/n]: y
Building kidletime from frameworks (40/60)
...
Rebuilding because the option refresh-build was set
Compiling... succeeded (after 11 seconds)
Installing kidletime succeeded (after 3 seconds)
Building plasma-activities from kf6-workspace-modules (41/20) # <-- continuing as normal
...
The other way of how it may work is command line option:
$ kde-builder dolphin
...
... # building modules, install succeeded
...
Building kidletime from frameworks (40/60)
Fetching remote changes to kidletime
Merging kidletime changes from branch master
No changes to kidletime source code, but proceeding to build anyway.
Compiling... failed (after 3 seconds)
kidletime didn't build, stopping here.
<<< PACKAGES SUCCESSFULLY BUILT >>>
kidletime
$ kde-builder dolphin --start-from-refresh-last-failed
Building kidletime from frameworks (40/60)
Fetching remote changes to kidletime
Merging kidletime changes from branch master
No changes to kidletime source code, but proceeding to build anyway.
Compiling... failed (after 3 seconds)
...
This assumes you do not use --stop-on-failure. Also related: #70
Edited by Andrew Shark