[DEV] Standalone python scripts
I have been experimenting lately with some python scripts using the concept of http://code.google.com/p/android-scripting/
however i found the interface limiting in lots of places.
- you can't run applications on console directly.
- you have environmental limitations.
- you can't pass command-line arguments.
so while searching for solution i have came across python standalone
however this script itself had some shortcommings including path errors.
so i have worked on this and found an optimal solution so here is the customized script.
These changes allow for following things.
- allow us to use this shell script to call python.
- allows for command line argument passing.
- relative path references are now working
what i have setup at my system is as follows
- script is named as py and placed at /system/bin/
- chmod 755 /system/bin/py
- so now i can naviagate to any folder and just type py followed by script name to execute it.
This should help in quick porting and testing of scripts in android handset, and small name should help in making it easy to work on virtual terminal.
However we cann't undermine the SL4A project coz the project is there to provide interfacing between android and python.
I will try to keep updating all the python scripts that i have been able to run hope others can also contribute to it.