0

I am on OS X Mavericks running a python script that requires a filename as command line argument like this

python name_of_my_script -i /path/to/input_file/file_name

Navigating to the directory containing the input file works by using tab completion in the shell. However, as I reach the right directory hitting TAB does not provide a list of files in the folder such that I could choose the right input file for the script. Also typing the first letters or two does not solve the problem. Hence, I am left with typing the name of the file by hand which is troublesome and causes a lot of errors.

The same error occurs with tab completion for example in git or pip but the python problem is the most crucial to me. Any help regarding this topic is highly appreciated.

marc
  • 81
  • 1
  • 5
  • how is the `/path/to/input_file` ? try using `~/path/to/file/...` – PepperoniPizza Jul 03 '14 at 16:20
  • it's a relative path: ../calcuations/some_python_pickle.p. I only get to ../calculations/ and then Tab completion is not working anymore. Using absolute paths is also not solving the problem. – marc Jul 03 '14 at 16:24
  • Does the file name end with `.py` or `.p` or something else? Does it work with file names that end in `.py`? – Etan Reisner Jul 03 '14 at 23:11
  • It's not working with any file extension. However, my problem seems to be related with this other post of mine: http://goo.gl/bb6tJ1. If I comment the corresponding lines in my .bash_profile the problem vanishes. – marc Jul 05 '14 at 11:21

0 Answers0