tortoise hg - How to install TortoiseHG on Ubuntu

25
2013-11
  • Webnet

    I just downloaded and installed the latest Ubuntu and it doesn't look like I'm used to. I don't see any Mercurial developer tools in the Ubuntu Software Center. I got on http://tortoisehg.bitbucket.org/download/index.html and it looks like it can be done, but I'm not entirely sure how. I've done some Googling but the results I keep running into are on older versions of Ubuntu. Any ideas on how I can make this happen?

  • Answers
  • prunge

    Are you using Unity or Gnome 3? TortoiseHg is a Nautilus extension so will only work with Gnome.

    There also seems to be issues being reported with TortoiseHg's compatibility with Gnome3:

    http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=644697

    https://bitbucket.org/tortoisehg/thg/issue/869/tortoisehg-nautilus-doesnt-work-at-all

    Don't know whether these issues have been fixed in the latest version of TortoiseHg. It might be worth trying with the TortoiseHg PPA to get the latest version, as the version that is in the standard Ubuntu repositories tend to lag behind a bit.


    Update:

    There's some info here regarding it working again in 12.10.

  • Sandro Dzneladze

    GUI is overrated, ubuntu includes terminal tools for svn.

    type svn diff type svn checkout type svn export

    much better than any GUI I've seen so far.


  • Related Question

    How do you track which packages were installed on Ubuntu (Linux)?
  • quark

    (This question is very similar to 10458. It was suggested that Fedora and Ubuntu/Debian are different enough to warrant different answers.)

    As I use any Ubuntu setup I gradually install a number of packages over and above the baseline installation. If I reinstall, or if I need to install a new machine, I usually want to reinstall those specific packages, and I want to do it fast to get back to work with a minimum of hassle. As far as I've seen all of the package managers (apt-get, aptitude and synaptic) can tell me which packages are installed, and they all have logs (albeit different ones for each tool, which is a hassle). But none of them can tell me which packages I've installed, as opposed to their dependencies or system updates. Even the logs are tricky in that I'm not entirely sure what I should be extracting from them, or how to integrate them (in the case of the various apt family tools). This means that each time I re-install, or even just backup, I'm not sure how to re-create that list.

    I'm not necessarily expecting any of the tools to do this for me, but if they don't I'm looking for workarounds. Even patterns to grep for, good rules of thumb, or a clear idea of what exactly is being logged, would be useful. There may not be a "best answer" here but good ones would be very helpful.


    Most of the answers below provide some approximation of what I am looking for, and are useful to some degree. The chosen one is the one that comes closest to a reasonably automatic way of re-installing my tools on a new system, even with all its caveats.


  • Related Answers
  • Telemachus

    On any Debian based machine, this is one common way to duplicate a package set. On the old machine:

    dpkg --get-selections "*" > my_favorite_packages
    

    Copy the file my_favorite_packages to the new machine (a thumb drive is a good option, but scp also works fine). Then run this sequence (with root privileges):

    apt-get update
    dpkg --set-selections < my_favorite_packages
    apt-get -u dselect-upgrade
    

    This doesn't get you only the packages you installed. It also gets their dependencies, etc. Also, if the repositories between the two machines are different, all bets are off.

    As far as logs, apt-get keeps a log at /var/log/apt/history.log (thanks to Tshepang for updating this in a comment); dpkg does (at /var/log/dpkg.log), but it's famously hard to parse and can only be read with root privileges; aptitude has one at /var/log/aptitude and you can page through it with regular user privileges.

    As far as I can tell, you are right that none of these logs track specifically what you installed as opposed to auto-installed dependencies. You can get that information, however, from an aptitude search. Search for all installed packages that were also installed automatically:

    aptitude search '~i ~M'
    

    If you want only the ones you installed (not the auto-dependencies), negate the ~M:

    aptitude search '~i !~M'
    

    If you want that formatted so that you have only the names of packages and the word "install", aptitude can do that too. This gives you a list ready to feed to dpkg --get-selections:

    aptitude search '~i !~M' -F "%p install"
    

    (I've got nothing on RedHat or RedHat-based systems. Sorry. There really is no one answer for Linux per se since package management is a big part of what makes different distros different.)

  • Ludwig Weinzierl

    Use dpkg -l '*' > jaunty.original to remeber all installed packages on a freshly installed system.

    After you have installed all your additional packages do dpkg -l '*' > mysystem.2009017.

    The additional packages are just the difference: diff jaunty.original mysystem.2009017

  • J. Pablo Fernández

    Aptitude is actually quite good at this. Aptitude does know when something was installed by hand or by dependency and you can tell it to remove things that are no longer needed and were only installed because something else depended on it always keeping up your system as small as possible.

    There's a handful of packages that make up an Ubuntu installation, ubuntu-minimal, ubuntu-desktop, ubuntu-server and so on. If you tell Aptitude to mark those as manually installed and remove everything else, then you end up with the minimum amount possible of packages.

    I explain how to do all that in two posts at my blog: Cleaning up a Debian GNU/Linux and Cleaning up a Debian GNU/Linux (or Ubuntu), reprise. In short, the answer you are looking for is:

    aptitude search ~i | grep -v "i A"
    

    The last time I worked with that, if you used apt-get, then it didn't work. That's why I always recommend aptitude and as far as I know, Debian is deprecating apt-get in favor of aptitude.

    I don't know how to do it on Fedora and you should probably separate than into a different question. Fedora and Ubuntu are different operating systems and should be treated as such (even if they share their kernel and some other stuff).

  • seb

    On debian apt-show-versions shows the versions of the installed packages.

  • Stefano Borini

    I am biased, and the solution I present is not always possible, but I got tired of this situation. The result is that I don't install anything anymore with the update/package manager tools.

    I took a quite hard route though (I had strict requirements for versions). I created a huge makefile which downloads, compiles and install in my home directory every package (program, library, whatever) I need. I developed it stepwise, piece by piece. The makefile downloads and compiles everything, even the compilers.

    When I move to a new system, or reinstall, I just copy the makefile (plus some supporting stuff), run make world and come back the next day.

    For some programs I develop (so I have control on), I use a tool I programmed, chestnut package manager. Sort of like .app folders on MacOSX. Everything is in the package, so I know what is installed at any time, and I know it's self contained and self sufficient (except for system libs)

  • Wade

    On apt-based systems look at /var/log/apt/term.log. For me, there's a pretty clear line to draw where the installation ended and where my installations began.

  • intuited

    From man aptitude-create-state-bundle:

    aptitude-create-state-bundle produces a compressed archive storing the files that are required to replicate the current package archive state.

    This will retain the same information that aptitude has on which packages were manually installed.

    It's meant to be used with aptitude-run-state-bundle:

    aptitude-run-state-bundle unpacks the given aptitude state bundle created by aptitude-create-state-bundle(1) to a temporary directory, invokes on it with the supplied , and removes the temporary directory afterwards.