What is the djvu2pdf.rb in Homebrew?

0

I recently downloaded a textbook as a .djvu file (sighs, not a PDF. wth is this). I found a way to view it and a way to convert it on the Internet (cool).

Recently however, I downloaded Homebrew for my Mac, and I found a strange file that was called djvu2pdf.rb (this sounds like it does what I want it to do) inside of the folder ~/homebrew/Library/Formula.

Among the spotlight search for djvu I did were these files:
spotlight search

What is this file for? Does it have anything to do with converting a .djvu to a .pdf? If so, how do I use it?

michaelsnowden

Posted 2014-01-22T01:13:03.683

Reputation: 656

Answers

1

It's a formula for a program that Homebrew can install for you (with brew install djvu2pdf). To find out more about the program, type brew home djvu2pdf to open up its home page in your default browser (that's true of all Homebrew formulas).

echristopherson

Posted 2014-01-22T01:13:03.683

Reputation: 771

In Homebrew's terminology, a "formula" is a set of instructions written in the Ruby programming language to install a software with Homebrew (which is also written in Ruby.) It is not the software you want to install itself. – nodakai – 2014-01-23T01:55:20.363

Now that I've installed it, since there is no help from the manpages or online about what the app does, where do I find this application on my computer? I can't run it from the command line because I don't know how it operates.

– michaelsnowden – 2014-01-23T03:48:28.770

You might want to read up on how Homebrew works, e.g. read https://github.com/Homebrew/homebrew/wiki. Basically Homebrew provides a bunch of formulas, which (as nodakai said) are Ruby scripts that install software from various places. The actual files belonging to each package are located in /usr/local/Cellar/<formula_name>/<version> -- or in your case, ~/homebrew/Cellar/<formula_name>/<version>. If Homebrew's installed in the default place, they then get symlinked into /usr/local/{lib,share,bin,etc.}; but since you have it in ~/homebrew I'm not sure where the links go.

– echristopherson – 2014-01-23T23:30:20.940