shang
shang

Reputation: 34

how to configure project type in pycharm for create django application

i want to create django project in pycharm. but there is no 'project type' list available in pycharm 4.5.3 i tried in internet and got the following:

In Run -> Edit Configurations create new configuration Script: path_to/manage.py Script parameters: runserver

how to do this and geeeting start with django project with pycharm

how to configure for that.?

Upvotes: 1

Views: 5451

Answers (1)

slawiko
slawiko

Reputation: 73

UPDATE:

You can't choose "Django project" because you use Community edition of PyCharm. Here you can learn more. There are three ways:

  1. You purchase full version.
  2. You download a trial-version.
  3. (if you're student) You can visit this link.

ENDUPDATE

If I completely understand your question: you want to create Django project in PyCharm? If yes, you have to click File -> New project -> Django. Then you should create virtual environment. Click on cogwheel on the right (hint image) -> Create virtualEnv. Then choose Name, Location and base interpreter (it is interpreter, that will use to configure virtualenv. I recommend Python 3.x). Click OK. Enter application name. Check "Enable Django admin" (I think you want to use it). And finally click "Create".

Good practice if you will work with your project in virtualenv. For that you should enter to project_root directory, and run

$ source bin/activate

That will switch your console to virtual environment. For more info you can ask google.

Now you can run your django server in two ways:

  1. Type in console python manage.py runserver
  2. Edit configurations in PyCharm (that will be very easy)

That's it! I hope I helped you.

Upvotes: 6

Related Questions