获取 Django版本号的两种方式
one
k@ubuntu:~$ python Python 2.7.6 (default, Nov 23 2017, 15:49:48) [GCC 4.8.4] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>> import django >>> django.VERSION (1, 11, 3, u'final', 0) >>> exit()
two
k@ubuntu:~$ python -m django --version 1.11.3 k@ubuntu:~$
参考: