Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I would like to download GIMP (the open source graphics application) onto my Mac. I don't want to run GIMP but rather view the source code. I have a vague understanding of tar balls (.tar.bz2) and don't know how to extract the code from the file.

Is there a simple command that I can just type into the terminal to get the source? A step-by-step guide would be helpful too.

Thanks.

share|improve this question

migrated from stackoverflow.com Jan 20 '11 at 9:58

This question came from our site for professional and enthusiast programmers.

    
my favorite (i have no idea why i prefer it over the much simpler tar xjvf gimp.tar.gz tho): bzip2 -cd gimp.tar.gz | tar xvf - –  Jason Coco Jan 20 '11 at 5:07
1  
Download the file, and double click on it. OS X knows how to handle tar files. –  user7541 Jan 20 '11 at 5:29
    
You might be interested in Seashore, homepage - seashore.sourceforge.net/The_Seashore_Project/About.html source - sourceforge.net/scm/?type=svn&group_id=71670 –  tobylane Jan 20 '11 at 23:24
add comment

3 Answers

up vote 6 down vote accepted
curl ftp://ftp.gimp.org/pub/gimp/v2.6/gimp-2.6.11.tar.bz2 --O gimp-2.6.11.tar.bz2
tar -jxvf gimp-2.6.11.tar.bz2

The first line (curl ...) downloads the latest source tar ball from gimp's servers to the local directory. The second line (tar ...) extracts the files. The flags passed to tar are j,x,v, and f and then the file to extract.

  • The j flag tells tar to extract a bzip2 compressed file.
  • The x flag tells tar to be in extract mode.
  • The v flag tells tar to be 'verbose' (i.e. tell you what it's doing)
  • The f flag is what is receiving the filename as its parameter.
share|improve this answer
2  
No wget on a default Mac install. Try curl. –  Thilo Jan 20 '11 at 5:09
    
@Thilo: Thanks, didn't realize that, I think wget was one of the first things I installed from ports when I got a Mac. –  Reese Moore Jan 20 '11 at 5:15
    
@Reese: Fantastic, that worked. –  David Jan 20 '11 at 5:22
add comment

Did you not see the download section? They show you the FTP details right there for the source files. I'm confused how 'easy' you want this?

Compiling from source is not easier than an installer...

http://www.gimp.org/downloads/

To extract a tar.bz2:

tar -jxvf gimp-2.6.11.tar.bz2
share|improve this answer
add comment

You can just double-click any .tar.bz2 file on Mac OS X. It will decompress and then untar in the same directory.

share|improve this answer
2  
and on the command line, just use open instead of tar <options>. –  mouviciel Jan 20 '11 at 10:14
    
I initially tried double clicking the first time and it didn't work, so I went back and tried it again and it worked. Really weird. Thanks. –  David Jan 20 '11 at 18:49
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.