Printable Version of Topic

Click here to view this topic in its original format

Linuxhelp _ Technical Support _ ls-la unknown color scheme in terminal mode

Posted by: eightbits Oct 19 2013, 08:34 PM

Hello, new user here. I recently downloaded and unziped a file that contains examples of python files. Once unziped, in terminal mode the listing of
that directory shows the directories in that directory as a green background and blue foreground. I do not find a reference to that color scheme,
I am using Ubuntu 12.04.
The directories are named such as: Chapter-01 up to Chapter-18 .

The problem: I can not execute the example files using ".\" as I can do with other py files (using the terminal mode).
I also get an error message that this is not a dirctory.
I CAN execute the file by using "python"
Other files not in this directory execute as been in the past.
Also, I can not execute the file(s) using the Desktop file menu. I have insured that the py files have execute permission as well.

The pythonfiles/ scripts run as expected using IDLE the python IDE.

This has me stumped and probally a simple way to understand, except for me :-).

I am thinking this has something to do with the way the zipped file was extracted but don't have a clue. I used the archive tool that is executed when I click on the

I am hoping that I can get some insight so I can continue on in learning to use GUI Python code.

Thanks for any help.

PS: I do have a screen capture if required and I know how to post it.

Posted by: michaelk Oct 20 2013, 11:26 AM

Difficult to say what the problem is but here are some things to check.
Make sure you are using the correct shebang in the first line of your program.
Make sure the permissions are set for executable
Make sure you are using the correct syntax to run the program i.e ./
If there are spaces in the file name make sure you escape the space or use quotes.
The example program might have errors and or expect different directories.

Posted by: eightbits Oct 20 2013, 08:01 PM

Thanks michaelk for the reply. As I mentioned in the OP I set the permissions for execute and used the terminal mode in the same directory as the python file/script and used the command
"./" to execute the file. I get a error message : No such file or directory even though it is in the directory listing. Strange that it is in the directory listing.
As other files execute in this manner I am thinking it has something to do with extracting the zip file (?).
If I go up one level all of the directories then show up with a GREEN background and BLUE foreground. So, I guess there doesn't seem to be an easy answer.
Strange that it does execute if I call the file from python at the command mode, "python". It then executes as expected.

Another question: Is wxpython an active and well supported toolset?

Once again, thanks for your reply.

Posted by: michaelk Oct 21 2013, 07:36 AM

Yes wxpython is active.

Is the permissions for the directory set as execute?

Posted by: eightbits Oct 21 2013, 08:47 PM

QUOTE (michaelk @ Oct 21 2013, 07:36 AM) *
Yes wxpython is active.

Is the permissions for the directory set as execute?

Yes, the directory has mode 777 as the octal value for permissions. I am wondering, can the ./ have a path issue? Other scripts do execute (py scripts/files) do just fine.
Really confusing.....

Quaestion: Can a graphics file (bmp, png ...) be inserted on this forum? I called my self searching but didn't find anything.

Posted by: michaelk Oct 22 2013, 09:59 AM

I'm confused too...

The . in ./ is a shortcut for current working directory. The command pwd will display the current working directory.
Try using the complete path. If spaces exist in the path or file name then use quotes.


Powered by Invision Power Board (
© Invision Power Services (