Permalink
Browse files

Fixed some typo in documentation

  • Loading branch information...
1 parent 9933cb8 commit b280f11adb3bb9a511251c4f0e2ce2e2935dd2b8 Alberto Paro committed Nov 14, 2011
Showing with 15 additions and 15 deletions.
  1. +8 −8 doc/source/example.rst
  2. +7 −7 doc/source/settings.rst
View
@@ -1,11 +1,11 @@
Pypi Example
------------------------------------
+------------
Lets make a scraper that extract data from the pypi's front page
http://pypi.python.org/pypi
-Supose that we want extract data from the packages table and
+Suppose that we want extract data from the packages table and
store it in a database.
First at all we need to start a new crawley's project. In this case
@@ -16,13 +16,13 @@ it will be called pypi_packages.
crawley startproject pypi_packages
cd pypi_packages
-Then, inside the pypi_packages there will a settings.py file and another
+Then, inside the pypi_packages there will a settings.py file and another
directory containing a crawlers.py file and a models.py file.
-Lets start defining the models.py wich is very simple in this case.
+Lets start defining the models.py which is very simple in this case.
Models
-===========
+======
.. code-block:: python
@@ -42,7 +42,7 @@ Ok, now is time to code. Lets make the scraper. It must be located inside
the crawlers.py file
Crawlers
-===========
+========
.. code-block:: python
@@ -89,8 +89,8 @@ Crawlers
extractor = XPathExtractor
-The interesting part of this is the scrape method defined inside the
-pypiScraper class. It uses Xpath in order to obtain the parsed html
+The interesting part of this is the scrape method defined inside the
+pypiScraper class. It uses XPath in order to obtain the parsed html
and then stores the extracted data in the Packages table.
At this time we have finished our work. Very simple. Isn't it?
View
@@ -1,5 +1,5 @@
Settings File
------------------------------------
+-------------
The settings.py file is required in every crawley's project.
A common settings file looks like this:
@@ -34,8 +34,8 @@ Configure your database
The settings file provides you the capability for configure your database engine.
The followings are configuration examples for the database engines supported so far.
-Sqlite
-========
+Sqlite
+======
It doesn't support host and user parameters. So, set it to empty.
@@ -50,8 +50,8 @@ It doesn't support host and user parameters. So, set it to empty.
DATABASE_HOST = ''
DATABASE_PORT = ''
-MySql
-========
+MySql
+=====
.. note:: Requires MySQLdb module
@@ -78,8 +78,8 @@ Postgres
DATABASE_HOST = 'localhost'
DATABASE_PORT = '5432'
-Oracle
-========
+Oracle
+======
.. note:: Requires cx_Oracle module

0 comments on commit b280f11

Please sign in to comment.