Last active
January 5, 2018 09:16
-
-
Save otykhonruk/c112e41e71f398b126a9c2453bd3656c to your computer and use it in GitHub Desktop.
Example of minimal fully-functional django project.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from django import conf, http, urls | |
conf.settings.configure( | |
DEBUG = True, | |
ROOT_URLCONF = __name__ | |
) | |
def index(request): | |
return http.HttpResponse('hello') | |
urlpatterns = [ | |
urls.path('', index) | |
] | |
if __name__ == '__main__': | |
import sys | |
from django.core.management import execute_from_command_line | |
execute_from_command_line(sys.argv) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment