Fixing python.sh script to run Python in Terminal on all Android OS in an easier way by using  python.sh command or by any custom command

Hello,everyone.Today, I am going to share how to fix my old python.sh script which I had shared on my blog for using Python in Terminal and how to use python.sh command after fixing that.

At first,I would like to thank my friend Luiz who fixed the old python.sh script which I had shared with you all on this blog.

I consider that Python For Android  app and its Python library has been already installed by you.If,you are using my old python.sh script  which you have already copied to /system/bin ,set its permission as 777,and try to run Python in Terminal  with this command: python.sh  ,you will get error as shown in the screenshot:

This error is shown due to an error in first line of python.sh script as shown in screenshot:

#! /bin/sh 

You are able to use Python only by using this command which is long and complex to type:

sh /system/bin/python.sh


*Fixing python.sh  file:

Android executes commands from /system/bin or /system/xbin .So,we need to edit the first line of  python.sh script of /system/bin  directory as shown below in screenshot:

# !/system/bin/sh 

Save the file and check that it’s permission is assigned as 777.

Or,you can download my  fixed python.sh file from below.

Download Here: python.sh

Now,open Terminal app and use this simple command to run Python  as shown in screenshot:

python.sh


You can see Python running successfully on your Terminal.If you get any error,there might be some mistakes.You need to check your all steps carefully.T o run any file in current directory,you need to use this command:

python.sh filename.py


*Customising(Renaming) python.sh command to any desired name 

You can also rename python.sh file of /system/bin directory to whatever name you like . you need to remember that name and use that name as command to run Python.For example,I have renamed python.sh to gaurav as shown in screenshot:

Now,open Terminal app,and use the command gaurav (you use the name whatever you have given to python.sh file) ,you will see Python successfully running with your customised command as shown in screenshot:

You will see Python running successfully if everything is fine.Now,You have successfullychanged/customised python.sh command.You need to use that command every time to run Python.

Thanks everyone for reading this post.If you have any questions or you get any error,please post in Comments.

Advertisements

PED IDE FOR PyS60 2.0

This PED IDE is based on PyS60 2.0(Python 2.5.4) and has been developed by Ibnu Wahyudi.I  have been searching IDE based on PyS60 2.0  from long time so that i can write Python Scripts based on PyS60 2.0 instead of PyS60 1.45.Well,thanks to Ibnu Wahyudi who developed this and finally my search ended.So,download this IDE to write scripts based on PyS60 2.0(Python 2.5.4).It has also Text2 plugin(based on appuifw2 module).

Developer: Ibnu Wahyudi 

Download: Ped python2.5 – fix drive.zip

SIMPLE SERVER APP (InunxLABS) FOR SYMBIAN S60

SIMPLE SERVER by InunxLABS for Symbian S60 

Thanks to InunxLABS who created this amazing app.newscreenshotapp56

This is just an application for tweaking HTTP/HTTPS Requests, such as applications Cheexy on Symbian phone, Ispce, Proxomitron,Inject Header Query on Windows pc.

Requirements:
– SymbianS60 v3, v5, ^3, and up.
Python_2.0.0

Features:
– HTTP/HTTPS connection supported.
– Modify HTTP/HTTPS Query.(Inject Query/Reverse Query/FQ/BQ/MQ)


– Modify HTTP/HTTPS Header.
-Supports Fetchserver(GApp Proxy)
– Advanced HTTP mode options.
– Logger window.
– Multi threaded connections (cheexy killer).

-See your IP and check if any GPRS Trick is working or not by clicking on TEST IP

Download:

1.SIMPLE SERVER v1.02.76

2.SIMPLE SERVER v1.0.72

 

 

 

 

PED-PYTHON IDE FOR S60

Mobile Python IDE for Nokia S60 platform.

Ped is a mobile application created using Nokia’s Python port for the S60 mobile platform (PyS60). It is a text editor focused on writing, executing and debugging Python code directly on the mobile device. Additional features like comfortable built-in Python Shell make it a true mobile Python IDE. Check out the screenshots and see for yourself

Using this,we can write  and run PyS60 scripts on cellphone itself.

Download: PED

It requires PyS60.