1

I'm trying to upgrade Sublime Text editor in Mint 10 Linux, but they only have the tar.bz2 file available for download. Is there an easier way? I'm new to Linux, but I know you can install some programs with apt-get.

4
  • It depends on whether the version you're looking for is in the APT repository of your distribution.
    – H2CO3
    Oct 17, 2012 at 19:53
  • 1
    @H2CO3: Not everything is Aptitude. Oct 19, 2012 at 12:39
  • @TomWijsman Since OP wanted to use apt-get, I assumed he used a Debian-based distribution with APT available.
    – H2CO3
    Oct 19, 2012 at 12:42
  • @H2CO3: Which is the case, as it uses dpkg, just checking assumptions... :) Oct 19, 2012 at 12:44

3 Answers 3

4

.tar.bz2 represents two different file extensions. .tar is an extension that signifies a container. Originally, this container was a tape drive and tar was how you got data onto or off of it. It is similar to a .zip file, but it does NOT COMPRESS the data. .bz2 DOES compress the data. .zip is always available, but in Linux, .tar is the standard. It concatenates the files together with basic metadata. .bz2 has better compression than .zip files, anyhow. So, first .tar is applied, then .bz2.

Extracting it is as simple as this: tar xvjf filename.tar.bz2 The v is optional, It just gives you visual feedback on what it's doing. The x means you are telling it to extract data from the provided file. j means the input file is in bz2 compression format and the f means you are handling a file or device.

This is similar to doing bunzip2 filename.tar.bz2 followed by tar -xvf filename.tar. However, the former leaves the filename.tar.bz2 file itself intact while the latter actually decompresses the .bz2 file into a .tar file.

The CONTENTS of that file are what determines how the program itself is installed.

In the case of Sublime, it looks like it just contains the binaries of the program. Once extracted, it's ready to run. There are 2 options you can take to make this easily executable.

  1. Add the new path you created (or move Sublime to another folder) to your $PATH environment variable. This can be done like this towards the end of your .bash_profile or .bashrc: PATH=${PATH}:/path/to/sublime Note: Replace the /path portion with the real path of Sublime on your PC
  2. Create a symlink for the executable to a directory that already exists in your path, such as /usr/local/bin: ln -s /full/path/of/sublime.executable /usr/local/bin

If there are additional binaries with the install that must be executed, then option 2 will not be feasible.

0

I've been using webupd8's PPA for Sublime for over a year without any problems, check it out. It's much more convenient than playing around with tar balls and manual hacking and slashing.

https://launchpad.net/~webupd8team/+archive/sublime-text-2

0

On Mint 10 Linux I no idea, but in ubuntu you can add ppa, just search for google, sublime text will upgrade automatic

You must log in to answer this question.