Skip to content

Commit

Permalink
Changed summary, updated .rst
Browse files Browse the repository at this point in the history
  • Loading branch information
sananth12 committed Mar 9, 2015
1 parent 23fef35 commit 895d7a3
Show file tree
Hide file tree
Showing 2 changed files with 48 additions and 23 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
ImageScraper :page_with_curl:
============
A cool command line tool which downloads all images in the given webpage.
A cool command line tool which downloads images from the given webpage.

| Build Status | Version | Downloads |
| ------------ | ------- | ------------------- |
Expand Down
69 changes: 47 additions & 22 deletions README.rst
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
ImageScraper
=============
ImageScraper
============

A cool command line tool which downloads all images in the given
A cool command line tool to download images in the given
webpage.

+------------------+--------------------+--------------------+
Expand All @@ -10,11 +10,23 @@ webpage.
| |Build Status| | |Latest Version| | |PyPi downloads| |
+------------------+--------------------+--------------------+

Demo
^^^^

Click `here <http://showterm.io/d3aef5bc3f37cd49757d1#fast>`__ to see it
in action!

Download
--------

pip install(recommended)
~~~~~~~~~~~~~~~~~~~~~~~~
tar file:
~~~~~~~~~

Grab the latest stable build from **- Pip:
https://pypi.python.org/pypi/ImageScraper**

pip install (recommended):
~~~~~~~~~~~~~~~~~~~~~~~~~~

You can also download using pip:

Expand All @@ -36,16 +48,26 @@ Usage
$ image-scraper [OPTIONS] URL
You can also use it in your python scripts.

.. code:: py
import image_scraper
image_scraper.scrape_images(URL)
Options
-------

.. code:: sh
-h, --help Print help
-m, --max-images <number> Maximum number images to be scraped
-s, --save-dir <path> Name of the folder to save the images (default: ./images_<domain>)
-s, --save-dir <path> Name of the folder to save the images
-g, --injected Scrape injected images
--formats [ [FORMATS ..]] Specify the formats of images to be scraped
--max-filesize <size> Limit on size of image in bytes (default: 100000000)
--dump-urls Print the URLs of the images
--scrape-reverse Scrape the images in reverse order
If you downloaded the tar:
~~~~~~~~~~~~~~~~~~~~~~~~~~
Expand All @@ -54,38 +76,41 @@ Extract the contents of the tar file.
.. code:: sh
$cd ImageScraper/
$python setup.py install
$image-scraper --max-images 10 [url to scrape]
$ cd ImageScraper/
$ python setup.py install
$ image-scraper --max-images 10 [url to scrape]
If installed using pip:
~~~~~~~~~~~~~~~~~~~~~~~
Examples
--------
Open python in terminal.
Scrape all images
.. code:: sh
$image-scraper --max-images 10 [url to scrape]
$ image-scraper ananth.co.in/test.html
NOTE:
^^^^^
Scrape at max 2 images
A new folder called "images\_" will be created in the same place,
containing all the downloaded images.
.. code:: sh
Upgrading
---------
$ image-scraper -m 2 ananth.co.in/test.html
Check if a newer version if available and upgrade using:
Scrape only gifs and download to folder ./mygifs
.. code:: sh
$ sudo pip install ImageScraper --upgrade
$ image-scraper -s mygifs ananth.co.in/test.html --formats gif
NOTE:
^^^^^
By default, a new folder called "images\_" will be created in the
working directory, containing all the downloaded images.
.. |Build Status| image:: https://travis-ci.org/sananth12/ImageScraper.svg?branch=master
:target: https://travis-ci.org/sananth12/ImageScraper
.. |Latest Version| image:: https://pypip.in/v/ImageScraper/badge.png
:target: https://pypi.python.org/pypi/ImageScraper/
.. |PyPi downloads| image:: http://img.shields.io/badge/downloads-7k%20total-blue.svg
.. |PyPi downloads| image:: http://img.shields.io/badge/downloads-7.5k%20total-blue.svg
:target: https://pypi.python.org/pypi/ImageScraper

0 comments on commit 895d7a3

Please sign in to comment.