<commit_before>=====================
django-simpleadmindoc
=====================

Django-simpleadmindoc is a tool that helps creating documentation for
editors and administrators of django based website.

Simpleadmindoc is based on and produces documents for 
`Sphinx <http://http://sphinx.pocoo.org/>`_.

Main features:

1. ``djangoadmin`` Sphinx domain allows autodocumenting models.
   It also allowd referencing models and fields inside
   documentation while taking care of using verbose names,

2. ``docgenapp`` django management command allows fast creating of skeleton
   documentation for applications inside website.

Goal of simpleadmindoc is to make writing of documentation for editors and
administrators fast, flexible and easy.

Configuration
-------------

1. Add djangoadmin domain to sphinx coniguration (``conf.py``)::

    extensions = ["simpleadmindoc.ext.djangoadmindoc"]

2. Configure sphinx so it have have access to django website.
   Add website directory to ``sys.path`` and setup environment variable 
   ``DJANGO_SETTINGS_MODULE``::

        import sys, os
        sys.path.insert(0, os.path.abspath('../..'))
        sys.path.insert(0, os.path.abspath('..'))
        os.environ['DJANGO_SETTINGS_MODULE'] = 'example.settings'

3. Add `simpleadmindoc` to your settings `INSTALLED_APPS`.

Usage
-----

Example application
-------------------

Small example application and sample generated documentation for it is included.<commit_msg>update docs<commit_after>===========================
django-simpleadmindoc 0.4.0
===========================

Django-simpleadmindoc is a tool that helps creating documentation for
editors and administrators of django based website.

Simpleadmindoc is based on and produces documents for 
`Sphinx <http://http://sphinx.pocoo.org/>`_.

Main features:

1. ``djangoadmin`` Sphinx domain allows autodocumenting models.
   It also allowd referencing models and fields inside
   documentation while taking care of using verbose names,

2. ``docgenapp`` django management command allows fast creating of skeleton
   documentation for applications inside website.

Goal of simpleadmindoc is to make writing of documentation for editors and
administrators fast, flexible and easy.

Usage
-----

.. code-block:: rest

  .. djangoadmin:model:: books.Article

  Reference models :djangoadmin:model:`books.Article` or attributes
  :djangoadmin:attribute:`books.Article.headline`.

``djangoadmin:model`` directive in first line will autodocument all available
fields in ``Article`` model that is in ``books`` app.

References in second line will be replaced with verbose names and linked
to respective model / attribute.

Configuration
-------------

1. Add djangoadmin domain to sphinx coniguration (``conf.py``)::

    extensions = ["simpleadmindoc.ext.djangoadmindoc"]

2. Configure sphinx so it have have access to django website.
   Add website directory to ``sys.path`` and setup environment variable 
   ``DJANGO_SETTINGS_MODULE``::

        import sys, os
        sys.path.insert(0, os.path.abspath('../..'))
        sys.path.insert(0, os.path.abspath('..'))
        os.environ['DJANGO_SETTINGS_MODULE'] = 'example.settings'

3. Add `simpleadmindoc` to your settings `INSTALLED_APPS`.


Example application
-------------------

Small example application is included.
{'fraction_non_alphanumeric': 0.1315868714242698, 'fraction_numerical': 0.005118940078289671, 'mean_word_length': 3.9508196721311477, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '554183', 'n_tokens_mistral': 942, 'n_tokens_neox': 894, 'n_words': 333}