1👍
Since I haven’t gotten any answer from anyone I come up with the following in case anyone has the same question.
#qpy:console
import os
import os.path
projectname=raw_input("Enter project name: ")
projectdir="/mnt/sdcard/com.hipipal.qpyplus/projects/"+projectname
if os.path.exists(projectdir):
print "sorry project '"+projectname+"' already exists"
else:
print "Starting django project '"+projectname+"'"
os.makedirs(projectdir)
os.system("cd /mnt/sdcard/com.hipipal.qpyplus/lib/python2.7/site-packages/django/bin && python django-admin.py startproject "+projectname+" "+projectdir)
appname=raw_input("Enter your first app name: ")
print "Starting the first django app '"+appname+"'"
os.system("cd "+projectdir+" && python manage.py startapp "+appname)
print "You project and first app started successfully"
print "Find the project here '"+projectdir+"'"
print " and edit settings.py as necessory"
print " then run python manage.py runserver to start"
Thank you
- [Answer]-CSRF verification failed. Request aborted. in django ajax post
- [Answer]-Named groups in Django based off model field?
Source:stackexchange.com