Convert pdf to jpg for free on windows using open source tools

To convert pdf to jpg on windows you can use existing open source tools ImageMagic and GhostScript.

Get and Install latest ImageMagic from:

Ensure that you install with OLE support (for scripting with VBScript)

Get and install latest GPL version of Ghostcript from sourceforge

Unfortunately there is no GUI for ImageMagic but you can use script below, just save it in pdf2jpg.vbs – to run the script just drag all pdf files that you want to convert on script icon. The resulting images will have the same name but with jpg extension and they will be placed in the same directory as pdf files.

Set imageMagick = CreateObject("ImageMagickObject.MagickImage.1")
For Each name in Wscript.Arguments
       pdf = Replace(name, ".pdf", ".jpg")
       imageMagick.Convert name, "-resize", 650, "-quality", 80, pdf

With ImageMagic you can do lots of cool stuff like create, edit, compose, convert bitmap images, scale, flip, mirror, rotate, distort, shear and transform images, adjust image colors, apply various special effects, or draw text, lines, polygons, ellipses and Bézier curves.

For more information see command line and COM+ ImageMagickObject documentations.

Instead of VBScript you can use other languages.

, ,


[Ruby] Wyświetlanie definicji ze “Słownika Wyrazów Obcych Kopalinskiego”

To jest kod skryptu w Ruby do wyświetlania definicji ze “Słownika Wyrazów Obcych Kopalińskiego”. Pobierz plik kopalinski.rb.

Żeby użyć tego skryptu musisz mieć zainstalowanego Ruby-ego.

W terminalu wpisz:

kopalinski.rb Słownik

Skrypt wyświetli definicje słowa “Słownik”. Jeśli w słowniku Kopalińskiego nie ma jakiegoś słowa skrypt nie wyświetla nic.



JQuery Terminal Emulator Plugin

My new project JQuery Terminal Emulator. It’s a plug-in which can be used to add Command Line interface to your application. You can use it to easily create server configuration tool or can be help in debugging or testing server side of AJAX applications. You can put lots of options in one place.

You can create command line interface to JSON-RPC in one line of code. Just set the path to rpc service.


If you want to use authentication.

$('body').terminal("json-rpc-service.php", {

And when user type user and password it will call login rpc method, get the token and pass that token to all methods on the server when user type command. So when user type for example add-user foo it will call json-rpc add-user with parameters [token, “foo”, “”].

, , , , , , ,

1 Comment

Really strange thing with Fedora

Recently I’ve create icons for GTK and I’ve notice strange thing. If you put this comment:

    icon is vector   for gtk

    Copyright  (c)

    You should have received a copy  the GNU General Public License
    along with this program.  If not, see <<.


In svg file between xml prolog and svg root node, the file will not display in Nautilus. The same things is with icons.

here is link to example file.

This was tested on Fedora 14 64bit liveCD on VirtualBox

, , ,

Leave a comment

Best internet ad ever

I found this ad on web page. It’s in my opinion best advertising ever. This is ad from from polish firm that specialize in security training courses.

security training courses ad

The link in this ad lead to this page


Leave a comment

Python one liner for css file compression

I need a script to compress css file, and I wrote this python one liner to do this. It removes unnecessary white space and strip comments.

python -c 'import re,sys;print re.sub("\s*([{};,:])\s*", "\\1",
re.sub("/\*.*?\*/", "", re.sub("\s+", " ",'


Leave a comment

10 books every hacker should read

Steven Levy – Hackers: Heroes of Computer Revolution

Hackers early history. The story is split into three parts.

  1. Early days mostly at Tech Model Railroad Club and AI. Lab at MIT
  2. Hardware Hackers (Homebrew Computer Club and Woz)
  3. Game Hackers, history of early games mostly created in assembler and basic for apple computer

Sam Williams – Free as in Freedom

Book about Richard M. Stallman, the origin on Free Software Foundation and GNU/Linux. You can read this book online.

Paul Graham – Hackers and Painters

Compilations of Graham essays. Graham is creator of Viaweb, which become Yahho Store and designer of arc lisp dialect. If you want more you can find it on Graham web site

William Gibson – Neuromancer

Classic cyberpunk book. Gibson is a father of cyberpunk he coined the term “cyberspace”.

Lawrence Lessig – Free Culture

Book about Open Society, Free Licensing and Open Source. The book was relased on Creative Commons Attribution/Non-commercial license (by-nc 1.0). You can download the book from offical web site.

Harold Abelson, Gerald Jay Sussman – Structure and Interpretation of Computer Programs

Classic book about programming and solving problems, all examples are in scheme programming language. Sussman design Scheme with Guy L. Steele. You can watch video lectures by authors of this book. You can read it online.

Eric Raymond – The Art of UNIX Programming

Book about the history and culture of Unix programming, and a guide to create open source program in *nix environment. You can read it online.

Open Sources: Voices from the Open Source Revolution

Group of Essays about Open Source. The essays contained were written by Chris DiBona, Sam Ockman, Mark Stone, Brian Behlendorf, Scott Bradner, Jim Hamerly, Marshall Kirk McKusick, Tim O’Reilly, Tom Paquin, Bruce Perens, Eric Raymond, Richard Stallman, Michael Tiemann, Linus Torvalds, Paul Vixie, Larry Wall, and Bob Young. You can read this book online.

Open Sources 2.0 : The Continuing Evolution

Continuation of previous book. The authors of essays are Mitchell Baker, Chris DiBona, Jeremy Allison, Ben Laurie, Michael Olson, Ian Murdock, Matthew N. Asay, Stephen R. Walli, Russ Nelson, Wendy Seltzer, Jusus M. Gonzalez-Barahona, Gregorio Robles, Alotita Sharma, Robert Adkins, Boon-Lock Yeo, Louisa Liu, Sunil Saxena, Bruno Souza, Doc Searls, Tim O’Reilly,Pamela Jones, Andrew Hessel, Eugene Kim, Larry Sanger, Sonali K. Shah, Steven Weber, Jeff Bates, Mark Stone. read this book online

Eric Raymond – New Hacker’s Dictionary

Dead-tree version of Jargon File




%d bloggers like this: