Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Added examples of using startproject/app with URLs

thanks to Brent O'Connor for the idea and intial docs
  • Loading branch information...
commit d80d05fc673665fa614e65eb2c38b654ccf28235 1 parent 8e5573e
Preston Holmes authored November 15, 2012

Showing 1 changed file with 17 additions and 3 deletions. Show diff stats Hide diff stats

  1. 20  docs/ref/django-admin.txt
20  docs/ref/django-admin.txt
@@ -879,14 +879,19 @@ either the path to a directory with the app template file, or a path to a
879 879
 compressed file (``.tar.gz``, ``.tar.bz2``, ``.tgz``, ``.tbz``, ``.zip``)
880 880
 containing the app template files.
881 881
 
  882
+For example, this would look for an app template in the given directory when
  883
+creating the ``myapp`` app::
  884
+
  885
+    django-admin.py startapp --template=/Users/jezdez/Code/my_app_template myapp
  886
+
882 887
 Django will also accept URLs (``http``, ``https``, ``ftp``) to compressed
883 888
 archives with the app template files, downloading and extracting them on the
884 889
 fly.
885 890
 
886  
-For example, this would look for an app template in the given directory when
887  
-creating the ``myapp`` app::
  891
+For example, taking advantage of Github's feature to expose repositories as
  892
+zip files, you can use a URL like::
888 893
 
889  
-    django-admin.py startapp --template=/Users/jezdez/Code/my_app_template myapp
  894
+    django-admin.py startapp --template=https://github.com/githubuser/django-app-template/archive/master.zip myapp
890 895
 
891 896
 .. versionadded:: 1.4
892 897
 
@@ -954,6 +959,15 @@ when creating the ``myproject`` project::
954 959
 
955 960
     django-admin.py startproject --template=/Users/jezdez/Code/my_project_template myproject
956 961
 
  962
+Django will also accept URLs (``http``, ``https``, ``ftp``) to compressed
  963
+archives with the project template files, downloading and extracting them on the
  964
+fly.
  965
+
  966
+For example, taking advantage of Github's feature to expose repositories as
  967
+zip files, you can use a URL like::
  968
+
  969
+    django-admin.py startproject --template=https://github.com/githubuser/django-project-template/archive/master.zip myproject
  970
+
957 971
 When Django copies the project template files, it also renders certain files
958 972
 through the template engine: the files whose extensions match the
959 973
 ``--extension`` option (``py`` by default) and the files whose names are passed

0 notes on commit d80d05f

Please sign in to comment.
Something went wrong with that request. Please try again.