Purpose: For those of you who have used open source editor Notepad++ before, they know what I am talking about when you fall in love with this great editor. Unfortunately, only a Windows native installer exits at this point of time and hence Linux users who want to use this editor on a Linux distro has to face some disappointment. But all is not lost. In this post, we will learn how to install Notepad++ on your Linux system using Wine. I know somehow of you may not like Wine (the software) just like me but if you want Notepad++ then it is a necessary evil. So let’s get started…

Step 1: Download Notepad++ Installer

You can download the installer from Google Code here. I downloaded this in my home directory – /home/kushalk.

Step 2: Extract the tarball

# cd;
# tar -xzvf npp-installer-0.2.tar.gz
# ls npp-installer/
LICENCE  npp-installer.py  npp-installer.py~  README

Step 3: Install Wine and Python

The installer relies on Wine and Python as you will in the next few steps. So go ahead and install it.

# apt-get update
# apt-get install wine python

Step 4: Edit the installer file

Before you can start installing you need to modify the npp-installer.py file, otherwise you are likely to get the following error during install:

# cd npp-installer
# python npp-installer.py
"SyntaxError?: Non-ASCII character '\xa0' in file npp-installer.py on line 1, but no encoding declared; see http://www.python.org/peps/pep-0263.html for details"

In order to resolve the above error, simply edit the file, npp-installer.py, and remove the leading space, the first character, from the line. That’s the reason why we see the above error message.

# nano npp-installer.py

You will see a character like this (depending on the editor you chose to edit the file) at the very beginning of the file:


Delete the above character. Save and exit.

Step 5: Install Notepad++

Now you are all set-up to install Notepad++. Simply give the following command:

# python npp-installer.py

and answer some few basic questions.

Once it finishes installing, you can launch the Notepad++ executable (remember this is running through Wine) from the following location:

# cd;
# cd .wine/drive_c/Program\ Files/
# cd Notepad++/
# ../notepad++.exe

I don’t know any better way to access the “executable” other than the above. I don’t use Wine much. If you know any better method (ln -s does not work) please post it in the comments.

That’s it!

Happy Notepad’ing++!

Be Sociable, Share!