Installing Intellij IDEA sublime-text-2 on Ubuntu

he installation on Linux is traditionally more complicated. I wonder why people complain about the low number of Linux desktop users. 🙂 The IntelliJ IDEA download page mentions only two steps:web

  1. unpack the 「ideaIU-XX.Y.Z.tar.gz」 file using the command 「tar xfz ideaIU-XX.Y.Z.tar.gz」 and
  2. run 「idea.sh」 from the bin subdirectory.

However, this instructions don’t deliver IntelliJ as delivered in other platforms. People don’t go to the installation folder and execute the file idea.sh. They either create a desktop icon or add the bin directory to the path, but these steps are missing. So, in my understanding, the installation is not completed. To launch IntelliJ from anywhere in the command prompt:sublime-text

Become the root user:bash

sudo -i

Move the unpacked folder to 「/opt/idea」:intellij-idea

mv ideaIC-XX.Y.Z /opt/idea

Edit the file .bashrc:app

gedit ~/.bashrc

Add the following line to the end of the file:ide

export PATH=/opt/idea/bin:$PATH

Log out and log in to the change take effect.this

To add the launcher icon on the desktop, there is a soft and a hard way.idea

The Soft Way

Fortunately, IntelliJ can help you once you run it for the first time. In the welcome window, select 「Configure」:spa

intellij-configure

And then select 「Create Desktop Entry」.code

intellij-configure-desktop-entry

That’s it!

The Hard Way

As a good Linux user, you may prefer doing it the hard way, as follows:

Create a desktop file:

cd /opt/idea
gedit idea.desktop    

Copy the content bellow to the file:

      [Desktop Entry]
      Name=IntelliJ IDEA 
      Type=Application
      Exec=idea.sh
      Terminal=false
      Icon=idea
      Comment=Integrated Development Environment
      NoDisplay=false
      Categories=Development;IDE;
      Name[en]=IntelliJ IDEA

Install the desktop file:

desktop-file-install idea.desktop

Create a symlink:

cd /usr/local/bin
ln -s /opt/idea/bin/idea.sh /usr/local/bin/idea.sh

Finally, display the idea icon in dash:

cp /opt/idea/bin/idea.png /usr/share/pixmaps/idea.png

At this point, you will finally feel IntelliJ as an application, integrated with the desktop and always ready to be executed.

 

sudo apt-add-repository ppa:mmk2410/intellij-idea-community
sudo apt-get update
sudo apt-get install intellij-idea-community

 

sudo add-apt-repository ppa:webupd8team/sublime-text-2
sudo apt-get update
sudo sudo apt-get install sublime-text-2
相關文章
相關標籤/搜索