Display line number in eclipse

Right click the left side of the editor or use the shortcut Ctrl+F10  to show the menu, and then select the item as shown in the figure.

Selection_004

Advertisement

(Updated for 18.04)To show the same display session in Ubuntu by Chrome Remote Desktop

The default configuration of Chrome Remote Desktop in Ubuntu opens a new session instead the same desktop currently running.

To fix this, please follow these steps:

Stop it:
/opt/google/chrome-remote-desktop/chrome-remote-desktop –stop

Back it up:
cp /opt/google/chrome-remote-desktop/chrome-remote-desktop /opt/google/chrome-remote-desktop/chrome-remote-desktop.orig

Edit: /opt/google/chrome-remote-desktop/chrome-remote-desktop

Change this to the size I wanted.
DEFAULT_SIZES = “1920×1080”

Set the X display number to the current display number (obtain it with echo $DISPLAY from any terminal).

FIRST_X_DISPLAY_NUMBER = 0

Comment out sections that look for additional displays:

#while os.path.exists(X_LOCK_FILE_TEMPLATE % display):
# display += 1
Reuse the existing X session instead of launching a new one. Alter launch_session() by commenting out launch_x_server() and launch_x_session() and instead setting the display environment variable, so that the function definition ultimately looks like the following:

def launch_session(self, x_args):
self._init_child_env()
self._setup_pulseaudio()
self._setup_gnubby()
#self._launch_x_server(x_args)
#self._launch_x_session()
display = self.get_unused_display_number()
self.child_env[“DISPLAY”] = “:%d” % display #Pls change the quotes to plain quotes

Start it:
/opt/google/chrome-remote-desktop/chrome-remote-desktop –start

DONE. Now it attaches to Unity’s existing X Server on display :0.

Credit to the discussion of these post  https://productforums.google.com/forum/#!topic/chrome/LJgIh-IJ9Lk

https://superuser.com/questions/778028/configuring-chrome-remote-desktop-with-ubuntu-gnome-14-04

Run a 32-bit binary on a 64-bit Ubuntu

If the output of file file-name shows,

file-name: ELF 32-bit LSB  executable, Intel 80386, version 1 (SYSV), dynamically linked (uses shared libs), for GNU/Linux 2.x.x, not stripped

To run 32bit executable file in a 64 bit multi-arch Ubuntu system, we have to add i386 architecture and also we have to install 

libc6:i386,

libncurses5:i386,

libstdc++6:i386

these three library packages.

sudo dpkg --add-architecture i386
sudo apt-get update
sudo apt-get install libc6:i386 libncurses5:i386 libstdc++6:i386
sudo ./file-name

How to create a MATLAB launcher/shortcut

1. Get an icon:

sudo wget http://upload.wikimedia.org/wikipedia/commons/2/21/Matlab_Logo.png -O /usr/share/icons/matlab.png

2. Create the launcher file /usr/share/applications/matlab.desktop

[Desktop Entry]
Type=Application
Icon=/usr/share/icons/matlab.png
Name=MATLAB R2014a
Comment=Start MATLAB - The Language of Technical Computing
#Uncomment the following line and comment the line after to
#force matlab to use the 32 bits architecture
#Exec=matlab -arch=glnx86 -desktop
#please replace the following line with the path where matlab installed Exec=/media/Program/MATLAB_linux/R2014a/bin/matlab -desktop Categories=Development;

Compile Bundler in Ubuntu 12.04

1. Download the bundler-v0.4-source and install all  the required dependencies.

2. After make, we can see such error,

BundlerApp.h:620:32: error: cannot call constructor ‘SkeletalApp::BundlerApp’

3. The solution is to change “BundlerApp::BundlerApp();” to “BundlerApp();” in line 620 of the file of BundlerApp.h

Then we can make it successfully.

Install CUDA 5.0 in Ubuntu 12.04

1. The order of installing the Nvidia driver and CUDA 5.0 is not important.
2. The CUDA 5.0 requires Nvidia driver 304 or later.
3. Disable Nouveau by adding

blacklist nouveau

in /etc/modprobe.d/nvidia-graphics-drivers.conf

so that Nvidia driver can be actived.

4. Dependent library should be installed, such as libxmu-dev.

Problem:
After I installed Nvidia driver, tty1-tty6 is not working.
When I push ctrl+alt+F1~F6, only a blinking cursor on the screen.
Current solution:
If I need to use tty1-tty6, I first boot to recovery mode, and then normally strat Ubuntu. From this way, tty1-tty6 can be accessible again.