I have written a Python program to analyse a set of files present in a given directory, i.e. it asks for a path then it goes into the path directory and find specified files, process them and produces an output file. However, every time I want to execute the program on a UNIX machine I have to write python my_prog.py. Also, to process a directory the program must be copied to the directory first, then executed.
I want to make it so that in UNIX I type my_prog inside any directory the program be executed, which means getting rid of copying the program file to target directory. How can I do this?