Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
A web snapshot application written in ruby
Ruby
branch: master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
bin
spec
.document
.gitignore
.rspec
Gemfile
Gemfile.lock
LICENSE.txt
README.rdoc
Rakefile
VERSION
tmp.jpg
web-snapshooter-0.0.1.gem
web-snapshooter.gemspec

README.rdoc

web-snapshooter

Introduction

With web-snapshooter you can make those web-thumnails you always dreamed of. It allows to specify the browser size and the output size. It permits both jpg and png and 2 different engines (mozilla and webkit). You can also use it without the need of an X server, if you have installed xvfb it will take care of the creation of a dummy server where the render can be done.

Installation

First you have to install dependencies

Gtk2

sudo aptitude install libgtk2.0-dev # you have to install gtk2 and its development libraries
sudo gem install gtk2

Gtkmozembed

sudo aptitude install xulrunner-dev
sudo gem install gtkmozembed

Webkit

sudo aptitude install libwebkit-dev
git clone https://github.com/magec/rbwebkitgtk
cd rbwebkitgtk && ruby extconf.rb && make && sudo make install

Web-snapshooter

git clone git://github.com/magec/web-snapshooter.git  

cd web-snapshooter && gem build *gemspec && sudo gem install *.gem

Xvfb (in case you want to run it without a X server)

sudo aptitude install xvfb

Usage

Usage: web-snapshooter [options]
    -u, --uri URI                    The uri you want to take the spanshot from
    -e, --engine [webkit|mozilla]    Select the engine to be used (default is webkit)
    -f, --force                      Overwrite output
    -o, --output-file FILE           The output file
        --browser-size WIDTHxHEIGHT
                                     The size of the 'fake' browser that is going to be used to capture the snapshot, if not specified the output size will be used instead
        --output-size WIDTHxHEIGHT
                                   The size of the output file, if not specified the browser size will be used instead
    -x, --xvfb                       Use xvfb-run (this is needed if you have no X server or don't want to use it)
    -t, --timeout TIMEOUT            timeout for the request

Contributing to web-snapshooter

  • Check out the latest master to make sure the feature hasn't been implemented or the bug hasn't been fixed yet

  • Check out the issue tracker to make sure someone already hasn't requested it and/or contributed it

  • Fork the project

  • Start a feature/bugfix branch

  • Commit and push until you are happy with your contribution

  • Make sure to add tests for it. This is important so I don't break it in a future version unintentionally.

  • Please try not to mess with the Rakefile, version, or history. If you want to have your own version, or is otherwise necessary, that is fine, but please isolate to its own commit so I can cherry-pick around it.

Copyright

Copyright © 2011 Jose Fernandez (magec). See LICENSE.txt for further details.

Something went wrong with that request. Please try again.