2013-12-08

Django 1.6 source file count and directory structure

The other day i would like to know how many source files are there in Django 1.6, so I run the following command on the django directory.  Basically
it lists all non-empty python source files and count them.

$ ls -Rl django | grep \.py$ | grep -v " 0 " | wc -l
707

I would also like to know Django 1.6 directory structure, so I run the following command on the django directory again, limiting the tree depth to two:

$tree django -d -L 2
django
|-- bin
|   `-- profiling
|-- conf
|   |-- app_template
|   |-- locale
|   |-- project_template
|   `-- urls
|-- contrib
|   |-- admin
|   |-- admindocs
|   |-- auth
|   |-- comments
|   |-- contenttypes
|   |-- flatpages
|   |-- formtools
|   |-- gis
|   |-- humanize
|   |-- messages
|   |-- redirects
|   |-- sessions
|   |-- sitemaps
|   |-- sites
|   |-- staticfiles
|   |-- syndication
|   `-- webdesign
|-- core
|   |-- cache
|   |-- checks
|   |-- files
|   |-- handlers
|   |-- mail
|   |-- management
|   |-- serializers
|   `-- servers
|-- db
|   |-- backends
|   `-- models
|-- dispatch
|-- forms
|   `-- extras
|-- http
|-- middleware
|-- shortcuts
|-- template
|   `-- loaders
|-- templatetags
|-- test
|-- utils
|   |-- 2to3_fixes
|   |-- translation
|   `-- unittest
`-- views
    |-- decorators
    `-- generic