[maemo-developers] coding in python using os.system , (works on scratchbox but not on N900), Urgent pls help

From: Anderson Lizardo anderson.lizardo at openbossa.org
Date: Sun Nov 29 17:44:17 EET 2009
On Sun, Nov 29, 2009 at 11:36 AM, shampavman <shampavman18 at gmail.com> wrote:
> if anyone can confirm that something like this..
> os.system("ls > process_output.log")
> would work , it would be of really great help..
> Also if there are any alternatives to using os.system. I would like to
> know..

If all you want is to get a list of files of a directory, try os.listdir():

        listdir(path) -> list_of_strings

        Return a list containing the names of the entries in the directory.

                path: path of directory to list

        The list is in arbitrary order.  It does not include the special
        entries '.' and '..' even if they are present in the directory.

Anderson Lizardo
OpenBossa Labs - INdT
Manaus - Brazil
More information about the maemo-developers mailing list