On 7/23/10 12:44 AM, Tim Roberts wrote:
I wouldn't use os.system with grep and evaluate the return code. Instead
I'd use subprocess.Popen("file") and read the text output of the
commdn directly. By parsing that string, I can extract all kinds of
interesting information.
Small correction: subp
Holger brunck wrote:
>
>We are creating inside our buildsystem for an embedded system a cram
>filesystem
>image. Later on inside our build process we have to check the endianness,
>because it could be Little Endian or big endian (arm or ppc).
>
>The output of the "file" tool is for a little endi
>>> Something like the "file" utility for linux would be very helpfull.
>>>
>>> Any help is appreciated.
>
>>You're going to have to describe in detail what's in the file before
>>anybody can help.
>
> We are creating inside our buildsystem for an embedded system a cram
> filesystem
> image. Later
On 2010-07-21, Thomas Jollans wrote:
>> It would be possible to execute ret = os.system("file |
>> grep "little endian") and evaluate the return code. But I don't like
>> to evaluate a piped system command. If there is an way without using
>> the os.system command this would be great.
>
> Files
Thomas Jollans wrote:
On 07/21/2010 05:29 PM, Holger brunck wrote:
Something like the "file" utility for linux would be very helpfull.
Any help is appreciated.
You're going to have to describe in detail what's in the file before
anybody can help.
We are creating inside our buildsystem for an
On 07/21/2010 05:29 PM, Holger brunck wrote:
>
>>> Something like the "file" utility for linux would be very helpfull.
>>>
>>> Any help is appreciated.
>
>> You're going to have to describe in detail what's in the file before
>> anybody can help.
>
> We are creating inside our buildsystem for an
>> Something like the "file" utility for linux would be very helpfull.
>>
>> Any help is appreciated.
>You're going to have to describe in detail what's in the file before
>anybody can help.
We are creating inside our buildsystem for an embedded system a cram filesystem
image. Later on inside o
On 07/21/2010 08:02 AM, Grant Edwards wrote:
> On 2010-07-21, Holger brunck wrote:
>
>> I use python 2.5 and I am looking for a possibility to determine a
>> file type. Especially the endianness of a file is needed for me. Is
>> there a way to detect this easily in python?
>
> Only if you alread
On 2010-07-21, Holger brunck wrote:
> I use python 2.5 and I am looking for a possibility to determine a
> file type. Especially the endianness of a file is needed for me. Is
> there a way to detect this easily in python?
Only if you already know what's going to be in the file.
> Something like
Hi all,
I use python 2.5 and I am looking for a possibility to determine a file type.
Especially the endianness of a file is needed for me. Is there a way to detect
this easily in python? Something like the "file" utility for linux would be very
helpfull.
Any help is appreciated.
Best regards
Hol
10 matches
Mail list logo