[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: How to format the command output like MySQL output



On 10/20/2013 03:17 AM, 陶治江 wrote:
> 于 2013-10-20 0:53, Lars Noodén 写道:
>> On 19.10.2013 19:35, 陶治江 wrote:
>> [snip]
>>> I think it seems good like this, but I do not know how to make out
>>> it.(someone says awk, sed may help, but the environment does not
>>> permit it). Is there some libs or tools can help make output result
>>> good and elegent?
>> [snip]
>>
>> Perl would be the next step up, but if awk is not allowed then perl
>> certainly won't be.
>>
>> Regards,
>> /Lars
>>
>>
> 
> yes, the whole system size a extremely limited, so the only possible way
> is to find a suitable C lib to handle this.
> 
> What a big task!!!!

You could also port my Java solution:
http://pastebin.com/AFuCaQuB

It is most simple but not yet configured to display the lines -- a
feature you might consider to add in order to get your described output.

Another option would be the use of C printf() statements.

HTH
Linux-Fan

-- 
http://masysma.ohost.de/

Attachment: signature.asc
Description: OpenPGP digital signature


Reply to: