implement "pmbootstrap status"
Concept
@MartijnBraam had the idea of creating a status command, which is somewhat similar to "mrhlpr status". Basically showing a quick overview of the build environment, with sanity checks.
In mrhlpr, the output looks like this (refer to its README.md for more examples):
[OK ] First check
[OK ] Second check
[NOK] Third check
Checklist:
* Fix "Third check" issue by doing xyz
We don't need to stick to have exactly that format, but the idea is not to overwhelm the user with information, just tell them exactly what they need to know in this situation - for example if the kconfig check is not passing, then the next logical step is fixing the kernel config (we could show a short link to the wiki for details). (No need to show here why exactly it is not passing.)
Information to display
- device name and architecture
- pmbootstrap version
- path to checked out pmaports.git
Device independent checks
- pmaports.git status:
-
[NOK]
last "git fetch" was more than one day ago -
[NOK]
branch is not "up to date" ("git rebase origin/master" would not be noop; we have such a check in mrhlpr) -
[OK ]
on any branch that is based onorigin/master
, and last "git fetch" was less than one day ago
-
(maybe we can also move some CI checks here, like checking for "(CHANGEME!)" in the repository?)
Device specific checks
- kconfig check
In the future, we could display some kind of porting progress, and tell the user what they could work on next to make their device more functional (get some gamification elements going
So much for the idea, for an initial implementation I would suggest to implement this with just the "pmaports.git" check, because that is probably the most important one. We can extend it from there.
Suggestions to what else we could check are welcome. Who wants to take a shot at this?