Permalink
Browse files

replacing the old HTML user guide with a Sphinx-managed user guide

  • Loading branch information...
0 parents commit fa3f447a13728b03c23735f94ebd047ba9aba18b @derekjones derekjones committed Oct 5, 2011
Showing with 20,435 additions and 0 deletions.
  1. +130 −0 Makefile
  2. +63 −0 README.rst
  3. +22 −0 cilexer/README
  4. +1 −0 cilexer/cilexer/__init__.py
  5. +24 −0 cilexer/cilexer/cilexer.py
  6. +23 −0 cilexer/setup.py
  7. +164 −0 source/_themes/eldocs/layout.html
  8. +289 −0 source/_themes/eldocs/static/asset/css/common.css
  9. BIN source/_themes/eldocs/static/asset/img/ci-logo.gif
  10. BIN source/_themes/eldocs/static/asset/img/ee-logo.gif
  11. BIN source/_themes/eldocs/static/asset/img/grades.gif
  12. BIN source/_themes/eldocs/static/asset/img/mm-logo.gif
  13. BIN source/_themes/eldocs/static/asset/img/paper-ico.gif
  14. +789 −0 source/_themes/eldocs/static/asset/js/jquery-ui-min.js
  15. +18 −0 source/_themes/eldocs/static/jquery.js
  16. +60 −0 source/_themes/eldocs/static/pygments.css
  17. +3 −0 source/_themes/eldocs/theme.conf
  18. +2,177 −0 source/changelog.rst
  19. +257 −0 source/conf.py
  20. +856 −0 source/database/active_record.rst
  21. +152 −0 source/database/caching.rst
  22. +38 −0 source/database/call_function.rst
  23. +107 −0 source/database/configuration.rst
  24. +131 −0 source/database/connecting.rst
  25. +94 −0 source/database/examples.rst
  26. +59 −0 source/database/fields.rst
  27. +212 −0 source/database/forge.rst
  28. +88 −0 source/database/helpers.rst
  29. +29 −0 source/database/index.rst
  30. +112 −0 source/database/queries.rst
  31. +124 −0 source/database/results.rst
  32. +24 −0 source/database/table_data.rst
  33. +96 −0 source/database/transactions.rst
  34. +189 −0 source/database/utilities.rst
  35. BIN source/documentation/ELDocs.tmbundle.zip
  36. +195 −0 source/documentation/index.rst
  37. +56 −0 source/general/alternative_php.rst
  38. +41 −0 source/general/ancillary_classes.rst
  39. +23 −0 source/general/autoloader.rst
  40. +58 −0 source/general/caching.rst
  41. +68 −0 source/general/cli.rst
  42. +71 −0 source/general/common_functions.rst
  43. +258 −0 source/general/controllers.rst
  44. +99 −0 source/general/core_classes.rst
  45. +20 −0 source/general/creating_drivers.rst
  46. +187 −0 source/general/creating_libraries.rst
  47. +19 −0 source/general/credits.rst
  48. +39 −0 source/general/drivers.rst
  49. +46 −0 source/general/environments.rst
  50. +75 −0 source/general/errors.rst
  51. +123 −0 source/general/helpers.rst
  52. +98 −0 source/general/hooks.rst
  53. +6 −0 source/general/index.rst
  54. +31 −0 source/general/libraries.rst
  55. +52 −0 source/general/managing_apps.rst
  56. +117 −0 source/general/models.rst
  57. +98 −0 source/general/profiling.rst
  58. +11 −0 source/general/quick_reference.rst
  59. +8 −0 source/general/requirements.rst
  60. +66 −0 source/general/reserved_names.rst
  61. +133 −0 source/general/routing.rst
  62. +90 −0 source/general/security.rst
  63. +403 −0 source/general/styleguide.rst
  64. +88 −0 source/general/urls.rst
  65. +138 −0 source/general/views.rst
  66. +139 −0 source/helpers/array_helper.rst
  67. +156 −0 source/helpers/captcha_helper.rst
  68. +78 −0 source/helpers/cookie_helper.rst
  69. +457 −0 source/helpers/date_helper.rst
  70. +81 −0 source/helpers/directory_helper.rst
  71. +42 −0 source/helpers/download_helper.rst
  72. +49 −0 source/helpers/email_helper.rst
  73. +135 −0 source/helpers/file_helper.rst
  74. +506 −0 source/helpers/form_helper.rst
  75. +348 −0 source/helpers/html_helper.rst
  76. +9 −0 source/helpers/index.rst
  77. +79 −0 source/helpers/inflector_helper.rst
  78. +33 −0 source/helpers/language_helper.rst
  79. +45 −0 source/helpers/number_helper.rst
  80. +37 −0 source/helpers/path_helper.rst
  81. +67 −0 source/helpers/security_helper.rst
  82. +160 −0 source/helpers/smiley_helper.rst
  83. +167 −0 source/helpers/string_helper.rst
  84. +164 −0 source/helpers/text_helper.rst
  85. +48 −0 source/helpers/typography_helper.rst
  86. +313 −0 source/helpers/url_helper.rst
  87. +38 −0 source/helpers/xml_helper.rst
  88. BIN source/images/appflowchart.gif
  89. BIN source/images/arrow.gif
  90. BIN source/images/ci_logo.jpg
  91. BIN source/images/ci_logo_flame.jpg
  92. BIN source/images/ci_quick_ref.png
  93. BIN source/images/codeigniter_1.7.1_helper_reference.pdf
  94. BIN source/images/codeigniter_1.7.1_helper_reference.png
  95. BIN source/images/codeigniter_1.7.1_library_reference.pdf
  96. BIN source/images/codeigniter_1.7.1_library_reference.png
  97. BIN source/images/file.gif
  98. BIN source/images/folder.gif
  99. BIN source/images/smile.gif
  100. +45 −0 source/index.rst
  101. +69 −0 source/installation/downloads.rst
  102. +54 −0 source/installation/index.rst
  103. +19 −0 source/installation/troubleshooting.rst
  104. +20 −0 source/installation/upgrade_120.rst
  105. +125 −0 source/installation/upgrade_130.rst
  106. +30 −0 source/installation/upgrade_131.rst
  107. +28 −0 source/installation/upgrade_132.rst
  108. +44 −0 source/installation/upgrade_133.rst
  109. +72 −0 source/installation/upgrade_140.rst
  110. +71 −0 source/installation/upgrade_141.rst
  111. +100 −0 source/installation/upgrade_150.rst
  112. +39 −0 source/installation/upgrade_152.rst
  113. +28 −0 source/installation/upgrade_153.rst
  114. +47 −0 source/installation/upgrade_154.rst
  115. +76 −0 source/installation/upgrade_160.rst
  116. +27 −0 source/installation/upgrade_161.rst
  117. +45 −0 source/installation/upgrade_162.rst
  118. +27 −0 source/installation/upgrade_163.rst
  119. +56 −0 source/installation/upgrade_170.rst
  120. +27 −0 source/installation/upgrade_171.rst
  121. +48 −0 source/installation/upgrade_172.rst
  122. +90 −0 source/installation/upgrade_200.rst
  123. +38 −0 source/installation/upgrade_201.rst
  124. +33 −0 source/installation/upgrade_202.rst
  125. +62 −0 source/installation/upgrade_203.rst
  126. +22 −0 source/installation/upgrade_210.rst
  127. +57 −0 source/installation/upgrade_b11.rst
  128. +32 −0 source/installation/upgrading.rst
  129. +122 −0 source/libraries/benchmark.rst
  130. +220 −0 source/libraries/caching.rst
  131. +181 −0 source/libraries/calendar.rst
  132. +294 −0 source/libraries/cart.rst
  133. +181 −0 source/libraries/config.rst
  134. +269 −0 source/libraries/email.rst
  135. +173 −0 source/libraries/encryption.rst
  136. +276 −0 source/libraries/file_uploading.rst
  137. +813 −0 source/libraries/form_validation.rst
  138. +200 −0 source/libraries/ftp.rst
  139. +497 −0 source/libraries/image_lib.rst
  140. +9 −0 source/libraries/index.rst
  141. +273 −0 source/libraries/input.rst
  142. +291 −0 source/libraries/javascript.rst
  143. +88 −0 source/libraries/language.rst
  144. +259 −0 source/libraries/loader.rst
  145. +132 −0 source/libraries/output.rst
  146. +248 −0 source/libraries/pagination.rst
  147. +92 −0 source/libraries/parser.rst
  148. +90 −0 source/libraries/security.rst
  149. +317 −0 source/libraries/sessions.rst
  150. +170 −0 source/libraries/table.rst
  151. +149 −0 source/libraries/trackback.rst
  152. +104 −0 source/libraries/typography.rst
  153. +147 −0 source/libraries/unit_testing.rst
  154. +160 −0 source/libraries/uri.rst
  155. +150 −0 source/libraries/user_agent.rst
  156. +400 −0 source/libraries/xmlrpc.rst
  157. +146 −0 source/libraries/zip.rst
  158. +62 −0 source/license.rst
  159. +23 −0 source/overview/appflow.rst
  160. +106 −0 source/overview/at_a_glance.rst
  161. +16 −0 source/overview/cheatsheets.rst
  162. +46 −0 source/overview/features.rst
  163. +24 −0 source/overview/getting_started.rst
  164. +32 −0 source/overview/goals.rst
  165. +18 −0 source/overview/index.rst
  166. +27 −0 source/overview/mvc.rst
@@ -0,0 +1,130 @@
+# Makefile for Sphinx documentation
+#
+
+# You can set these variables from the command line.
+SPHINXOPTS =
+SPHINXBUILD = sphinx-build
+PAPER =
+BUILDDIR = build
+
+# Internal variables.
+PAPEROPT_a4 = -D latex_paper_size=a4
+PAPEROPT_letter = -D latex_paper_size=letter
+ALLSPHINXOPTS = -d $(BUILDDIR)/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) source
+
+.PHONY: help clean html dirhtml singlehtml pickle json htmlhelp qthelp devhelp epub latex latexpdf text man changes linkcheck doctest
+
+help:
+ @echo "Please use \`make <target>' where <target> is one of"
+ @echo " html to make standalone HTML files"
+ @echo " dirhtml to make HTML files named index.html in directories"
+ @echo " singlehtml to make a single large HTML file"
+ @echo " pickle to make pickle files"
+ @echo " json to make JSON files"
+ @echo " htmlhelp to make HTML files and a HTML help project"
+ @echo " qthelp to make HTML files and a qthelp project"
+ @echo " devhelp to make HTML files and a Devhelp project"
+ @echo " epub to make an epub"
+ @echo " latex to make LaTeX files, you can set PAPER=a4 or PAPER=letter"
+ @echo " latexpdf to make LaTeX files and run them through pdflatex"
+ @echo " text to make text files"
+ @echo " man to make manual pages"
+ @echo " changes to make an overview of all changed/added/deprecated items"
+ @echo " linkcheck to check all external links for integrity"
+ @echo " doctest to run all doctests embedded in the documentation (if enabled)"
+
+clean:
+ -rm -rf $(BUILDDIR)/*
+
+html:
+ $(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $(BUILDDIR)/html
+ @echo
+ @echo "Build finished. The HTML pages are in $(BUILDDIR)/html."
+
+dirhtml:
+ $(SPHINXBUILD) -b dirhtml $(ALLSPHINXOPTS) $(BUILDDIR)/dirhtml
+ @echo
+ @echo "Build finished. The HTML pages are in $(BUILDDIR)/dirhtml."
+
+singlehtml:
+ $(SPHINXBUILD) -b singlehtml $(ALLSPHINXOPTS) $(BUILDDIR)/singlehtml
+ @echo
+ @echo "Build finished. The HTML page is in $(BUILDDIR)/singlehtml."
+
+pickle:
+ $(SPHINXBUILD) -b pickle $(ALLSPHINXOPTS) $(BUILDDIR)/pickle
+ @echo
+ @echo "Build finished; now you can process the pickle files."
+
+json:
+ $(SPHINXBUILD) -b json $(ALLSPHINXOPTS) $(BUILDDIR)/json
+ @echo
+ @echo "Build finished; now you can process the JSON files."
+
+htmlhelp:
+ $(SPHINXBUILD) -b htmlhelp $(ALLSPHINXOPTS) $(BUILDDIR)/htmlhelp
+ @echo
+ @echo "Build finished; now you can run HTML Help Workshop with the" \
+ ".hhp project file in $(BUILDDIR)/htmlhelp."
+
+qthelp:
+ $(SPHINXBUILD) -b qthelp $(ALLSPHINXOPTS) $(BUILDDIR)/qthelp
+ @echo
+ @echo "Build finished; now you can run "qcollectiongenerator" with the" \
+ ".qhcp project file in $(BUILDDIR)/qthelp, like this:"
+ @echo "# qcollectiongenerator $(BUILDDIR)/qthelp/CodeIgniter.qhcp"
+ @echo "To view the help file:"
+ @echo "# assistant -collectionFile $(BUILDDIR)/qthelp/CodeIgniter.qhc"
+
+devhelp:
+ $(SPHINXBUILD) -b devhelp $(ALLSPHINXOPTS) $(BUILDDIR)/devhelp
+ @echo
+ @echo "Build finished."
+ @echo "To view the help file:"
+ @echo "# mkdir -p $$HOME/.local/share/devhelp/CodeIgniter"
+ @echo "# ln -s $(BUILDDIR)/devhelp $$HOME/.local/share/devhelp/CodeIgniter"
+ @echo "# devhelp"
+
+epub:
+ $(SPHINXBUILD) -b epub $(ALLSPHINXOPTS) $(BUILDDIR)/epub
+ @echo
+ @echo "Build finished. The epub file is in $(BUILDDIR)/epub."
+
+latex:
+ $(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex
+ @echo
+ @echo "Build finished; the LaTeX files are in $(BUILDDIR)/latex."
+ @echo "Run \`make' in that directory to run these through (pdf)latex" \
+ "(use \`make latexpdf' here to do that automatically)."
+
+latexpdf:
+ $(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex
+ @echo "Running LaTeX files through pdflatex..."
+ make -C $(BUILDDIR)/latex all-pdf
+ @echo "pdflatex finished; the PDF files are in $(BUILDDIR)/latex."
+
+text:
+ $(SPHINXBUILD) -b text $(ALLSPHINXOPTS) $(BUILDDIR)/text
+ @echo
+ @echo "Build finished. The text files are in $(BUILDDIR)/text."
+
+man:
+ $(SPHINXBUILD) -b man $(ALLSPHINXOPTS) $(BUILDDIR)/man
+ @echo
+ @echo "Build finished. The manual pages are in $(BUILDDIR)/man."
+
+changes:
+ $(SPHINXBUILD) -b changes $(ALLSPHINXOPTS) $(BUILDDIR)/changes
+ @echo
+ @echo "The overview file is in $(BUILDDIR)/changes."
+
+linkcheck:
+ $(SPHINXBUILD) -b linkcheck $(ALLSPHINXOPTS) $(BUILDDIR)/linkcheck
+ @echo
+ @echo "Link check complete; look for any errors in the above output " \
+ "or in $(BUILDDIR)/linkcheck/output.txt."
+
+doctest:
+ $(SPHINXBUILD) -b doctest $(ALLSPHINXOPTS) $(BUILDDIR)/doctest
+ @echo "Testing of doctests in the sources finished, look at the " \
+ "results in $(BUILDDIR)/doctest/output.txt."
@@ -0,0 +1,63 @@
+######################
+CodeIgniter User Guide
+######################
+
+******************
+Setup Instructions
+******************
+
+The CodeIgniter user guide uses Sphinx to manage the documentation and
+output it to various formats. Pages are written in human-readable
+`ReStructured Text <http://sphinx.pocoo.org/rest.html>`_ format.
+
+Prerequisites
+=============
+
+Sphinx requires Python, which is already installed if you are running OS X.
+You can confirm in a Terminal window by executing the ``python`` command
+without any parameters. It should load up and tell you which version you have
+installed. If you're not on 2.7+, go ahead and install 2.7.2 from
+http://python.org/download/releases/2.7.2/
+
+Installation
+============
+
+1. Install `easy_install <http://peak.telecommunity.com/DevCenter/EasyInstall#installing-easy-install>`_
+2. ``easy_install sphinx``
+3. ``easy_install sphinxcontrib-phpdomain``
+4. Install the CI Lexer which allows PHP, HTML, CSS, and JavaScript syntax highlighting in code examples (see *cilexer/README*)
+5. ``cd user_guide_src``
+6. ``make html``
+
+Editing and Creating Documentation
+==================================
+
+All of the source files exist under *source/* and is where you will add new
+documentation or modify existing documentation. Just as with code changes,
+we recommend working from feature branches and making pull requests to
+the *develop* branch of this repo.
+
+So where's the HTML?
+====================
+
+Obviously, the HTML documentation is what we care most about, as it is the
+primary documentation that our users encounter. Since revisions to the built
+files are not of value, they are not under source control. This also allows
+you to regenerate as necessary if you want to "preview" your work. Generating
+the HTML is very simple. From the root directory of your user guide repo
+fork issue the command you used at the end of the installation instructions::
+
+ make html
+
+You will see it do a whiz-bang compilation, at which point the fully rendered
+user guide and images will be in *build/html/*. After the HTML has been built,
+each successive build will only rebuild files that have changed, saving
+considerable time. If for any reason you want to "reset" your build files,
+simply delete the *build* folder's contents and rebuild.
+
+***************
+Style Guideline
+***************
+
+Please refer to source/documentation/index.rst for general guidelines for
+using Sphinx to document CodeIgniter.
@@ -0,0 +1,22 @@
+To install the CodeIgniter Lexer to Pygments, run:
+
+ sudo python setup.py install
+
+Confirm with
+
+ pygmentize -L
+
+
+You should see in the lexer output:
+
+* ci, codeigniter:
+ CodeIgniter (filenames *.html, *.css, *.php, *.xml, *.static)
+
+You will need to run setup.py and install the cilexer package anytime after cilexer/cilexer.py is updated
+
+NOTE: Depending on how you installed Sphinx and Pygments,
+you may be installing to the wrong version.
+If you need to install to a different version of python
+specify its path when using setup.py, e.g.:
+
+ sudo /usr/bin/python2.5 setup.py install
@@ -0,0 +1 @@
+
@@ -0,0 +1,24 @@
+import re
+import copy
+
+from pygments.lexer import DelegatingLexer
+from pygments.lexers.web import PhpLexer, HtmlLexer
+
+__all__ = ['CodeIgniterLexer']
+
+
+class CodeIgniterLexer(DelegatingLexer):
+ """
+ Handles HTML, PHP, JavaScript, and CSS is highlighted
+ PHP is highlighted with the "startline" option
+ """
+
+ name = 'CodeIgniter'
+ aliases = ['ci', 'codeigniter']
+ filenames = ['*.html', '*.css', '*.php', '*.xml', '*.static']
+ mimetypes = ['text/html', 'application/xhtml+xml']
+
+ def __init__(self, **options):
+ super(CodeIgniterLexer, self).__init__(HtmlLexer,
+ PhpLexer,
+ startinline=True)
@@ -0,0 +1,23 @@
+"""
+Install and setup CodeIgniter highlighting for Pygments.
+"""
+
+from setuptools import setup
+
+entry_points = """
+[pygments.lexers]
+cilexer = cilexer.cilexer:CodeIgniterLexer
+"""
+
+setup(
+ name='pycilexer',
+ version='0.1',
+ description=__doc__,
+ author="EllisLab, Inc.",
+ packages=['cilexer'],
+ install_requires=(
+ 'sphinx >= 1.0.7',
+ 'sphinxcontrib-phpdomain >= 0.1.3-1'
+ ),
+ entry_points=entry_points
+)
Oops, something went wrong.

0 comments on commit fa3f447

Please sign in to comment.