How to install the Qgit client in Ubuntu

Source: Internet
Author: User
Tags git client git clone

Qgit is an open source graphical interface Git client written by Marco Costalba in Qt and C + +. It is a client that can better provide browsing version history, viewing commit records and file patches in a graphical environment. It uses the git command line to execute and display the output. It has some general functions like browsing version history, comparisons, file histories, file annotations, archive trees. We can format and apply patches with the selected commits, drag and submit between two or more instances, and so on. It allows us to use its built-in generator to create custom buttons to execute specific commands.

Here are a few simple steps to compile and install the Qgit client in Ubuntu 14.04 LTS "Trusty".

1. Installing the QT4 Library

First, running Qgit in Ubuntu requires installing the QT4 library first. Since apt is the default package manager for Ubuntu and Qt4 is also in the official warehouse, we use the following Apt-get command to install QT4 directly.

$ sudo apt-get install Qt4-default

2. Download Qgit Compression pack

After installing QT4, we will install git so that we can clone the Git repository in qgit. Run the following Apt-get command.

$ sudo apt-get install git

Now, we're going to use the following GIT command to clone the Qgit client's repository.

$ git clone git://repo.or.cz/qgit4/redivivus.git

Cloning into ' redivivus ' ...

Remote:counting objects:7128, done.

Remote:compressing objects:100% (2671/2671), done.

Remote:total 7128 (Delta 5464), reused 5711 (Delta 4438)

Receiving objects:100% (7128/7128), 2.39 MiB | 470.00 kib/s, done.

Resolving deltas:100% (5464/5464), done.

Checking connectivity ... done.

3. Compiling qgit

After cloning, we now enter the Redivivus directory and create the makefile file we need to compile. Go to the directory and run the following command.

$ CD Redivivus

Next, we run the following command from the Qmake project file (Qgit.pro) to generate a new makefile.

$ qmake Qgit.pro

After generating the makefile, we can now finally compile the Qgit source code and generate the binary. First we install make and g++ packages for compiling, because this is a program written in C + +.

$ sudo apt-get install make g++

Now, we're going to compile the code with the make command.

$ make

4. Installing Qgit

After successfully compiling the source code for Qgit, we will install it in Ubuntu 14.04 so that it can be executed in the system. So we'll run the following command.

$ sudo make install

CD src/&& make-f Makefile Install

MAKE[1]: Entering directory '/HOME/ARUN/REDIVIVUS/SRC '

Make-f makefile.release Install

MAKE[2]: Entering directory '/HOME/ARUN/REDIVIVUS/SRC '

Install-m 755-p ". /bin/qgit ""/usr/lib/x86_64-linux-gnu/qt4/bin/qgit "

Strip "/usr/lib/x86_64-linux-gnu/qt4/bin/qgit"

MAKE[2]: Leaving directory '/HOME/ARUN/REDIVIVUS/SRC '

MAKE[1]: Leaving directory '/HOME/ARUN/REDIVIVUS/SRC '

Next, we need to copy the Qgit binary from the bin directory to/usr/bin/so that we can run it globally.

$ sudo cp bin/qgit/usr/bin/

5. Create Desktop Files

Now that we have successfully installed Qgit in Ubuntu, let's create a desktop file so that the qgit can be found in the menu or launcher in our desktop environment. To do this, we're going to create a new file in/usr/share/applications/called Qgit.desktop.

$ sudo nano/usr/share/applications/qgit.desktop

Next, copy the following lines into the file.

[Desktop Entry]

Name=qgit

Genericname=git Graphical Interface Viewer

Exec=qgit

Icon=qgit

Type=application

Comment=git Graphical Interface Viewer

Terminal=false

Mimetype=inode/directory;

Categories=qt;development; Revisioncontrol;

When you are finished, save and exit.

6. Running the Qgit client

After the Qgit installation is complete, we can now launch it from any launcher or program menu. To run Qgit under the terminal, we can do as below.

$ qgit

This will open the Qgit based on the QT4 framework graphical interface mode.

Summarize

Qgit is a great QT-based git client. It can run on all three platforms, Linux, MAC OSX, and Microsoft windows. It helps us to easily navigate through the information provided by the Git repositories, such as history, versions, branches, and so on. It reduces the need to use the command line to perform features such as browsing versions, history, and comparison, and simplifies these tasks in a graphical manner. The latest version of Qgit is also in the default warehouse, which you can install using the Apt-get install Qgit command. As a result, Qgit uses its simple graphical interface to make our work easier and faster. (Edit: Lelinpeng Source: Network)

How to install the Qgit client in Ubuntu

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.