When running "df -P", the output of the header columns is not aligned with the output rows in the same way that it is with running regular "df". This is also inconsistent with how "df -P" works on non-busybox versions of "df". The expected behavior is that each filesystem aligns as: column 1 is left aligned to the column header columns 2 through n-1 are right-aligned to their column header column n is left aligned to the column header The current behavior is that columns 2-n are not aligned with the filesystem rows below. This is an issue for me because I need to be able to scrape the output of "df -P" & column alignment is an important part of consistently scraping the output between busybox df & other versions of df.
Rows will also fall out of alignment if printed values are too large to fit into allotted number of characters. Wouldn't it be much simpler to parse the output by treating it as whitespace delimited list of numbers instead of matching character positions?
Simpler perhaps, but makes a different assumption, which is that none of the fields (ex, 'filesystem',' mounted on') will have spaces in them. For non-busybox versions of df, the column alignment being rigidly defined allowed me to control for potential field whitespace.