-
Notifications
You must be signed in to change notification settings - Fork 39
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
Format change for '-S' output #38
Comments
That change will ease output parsing. (closes GH issue #38)
Hello Harry, I've just pushed a change that modifies the global output format of files listed to stdout. The new format is as below :
and will be much easier to parse. Cheers, Ganael. |
I'll give it a try on the weekend. THANK YOU!!
harry
…On Thu, Mar 3, 2022 at 8:27 AM Ganael Laplanche ***@***.***> wrote:
Hello Harry,
I've just pushed a change that modifies the global output format of files
listed to stdout. The new format is as below :
partition_index file_size file_path
and will be much easier to parse.
Cheers,
Ganael.
—
Reply to this email directly, view it on GitHub
<#38 (comment)>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/AASF3Y5RUINLJC7RZGNDLY3U6DR6JANCNFSM5MOR5TRQ>
.
Triage notifications on the go with GitHub Mobile for iOS
<https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675>
or Android
<https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub>.
You are receiving this because you authored the thread.Message ID:
***@***.***>
--
Harry Mangalam
|
Hello Harry, Have you been able to test the change ? |
Hi Ganael,
It looks good:
$ ~/Downloads/fpart/src/fpart -L -S -s 200m -o ~/chunks/f ~/Downloads
S 327155712 /home/hjm/Downloads/RT-contents.ibd.most-of-rt-database.data
S 492830720 /home/hjm/Downloads/isos/debian-11.1.0-i386-netinst.iso
S 2009333760
/home/hjm/Downloads/isos/Fedora-Workstation-Live-x86_64-35-1.2.iso
S 3204448256 /home/hjm/Downloads/isos/kubuntu-20.04.3-desktop-amd64.iso
S 1902116864 /home/hjm/Downloads/isos/lmde-4-cinnamon-32bit.iso
...
I would prefer a less common delimiter than a space between the fields
since many filenames have spaces - a tab character would be more convenient
(for me) and easier to handle in general I think..?
ie:
instead of [file_entry.c:423] (I think)
fprintf(stdout, "S %ju %s\n", size, path);
use
fprintf(stdout, "S\t%ju\t%s\n", size, path);
And what is the purpose of the leading 'S'? Is that to differentiate these
lines from any other fpart STDOUT output? I can't tell from the src code
and surrounding comments. It's a hard-coded 'S', not a var.
I can certainly work with the 'S'; just interested in the rationale.
thanks!
Harry
.
…On Tue, Mar 8, 2022 at 3:31 AM Ganael Laplanche ***@***.***> wrote:
Hello Harry,
Have you been able to test the patch ?
—
Reply to this email directly, view it on GitHub
<#38 (comment)>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/AASF3Y25WQCTETYUQEOJUSLU643CLANCNFSM5MOR5TRQ>
.
Triage notifications on the go with GitHub Mobile for iOS
<https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675>
or Android
<https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub>.
You are receiving this because you authored the thread.Message ID:
***@***.***>
--
Harry Mangalam
|
Hi Harry, Right, it will also be cleaner. I have just pushed a change in that way. The 'S' letter means 'S'kipped, see issue #36. Cheers, Ganael. |
Sorry Ganael, I blanked on trying it. I'll do it later today. Sorry.
Harry
…On Tue, Mar 8, 2022 at 3:31 AM Ganael Laplanche ***@***.***> wrote:
Hello Harry,
Have you been able to test the patch ?
—
Reply to this email directly, view it on GitHub
<#38 (comment)>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/AASF3Y25WQCTETYUQEOJUSLU643CLANCNFSM5MOR5TRQ>
.
Triage notifications on the go with GitHub Mobile for iOS
<https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675>
or Android
<https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub>.
You are receiving this because you authored the thread.Message ID:
***@***.***>
--
Harry Mangalam
|
Hello Harry! No pb, take your time... the change is already available in the latest release. Cheers, Ganael. |
Hi Ganael,
The new '-S' (skip files larger than partition size) output format is the current output of '-S' is a bit noisy:
ie:
S (1902116864): /home/hjm/Downloads/isos/lmde-4-cinnamon-32bit.iso
Could this be simplifired to:
1902116864<tab>/home/hjm/Downloads/isos/lmde-4-cinnamon-32bit.iso
the '-v' output goes to STDERR so it can be filtered and that leaves a nicely segregated file
(lots of verbose STDERR output)
so rather than perform a couple of complex regex splits (OK, not very complex), all you need is simple (and usually default in many languages) split on whitespace.
The current format of the partition files is simply a list of fully qualified filename paths with no prefixes.
so the the simpler format suggested above is similar (prefixed with the byte size of the file.)
Thanks
Harry
The text was updated successfully, but these errors were encountered: