Tag Archives: tweaks

Fix VirtualBox 5.1.x Focus Issues On GNOME Desktops (Not Being Able To Move VM Windows In GNOME Shell, Clicking On Indicators In Unity)

If you use VirtualBox 5.1.x with a GNOME desktop (GNOME Shell, Unity and possibly other GTK-based desktops as well), you may have noticed that there are some focus-related issues:
  • in GNOME Shell (host), virtual machine windows can’t be moved unless clicking on another window, then moving the virtual machine window;
  • in GNOME Shell (host), the Activities Overview can’t be accessed if a virtual machine is focused;
  • in Unity (host), clicking on an indicator while a virtual machine is focused results in the indicator menus not being displayed.

Here’s a screenshot showing what happens in Unity when indicators are clicked while a VirtualBox 5.1.x virtual machine is focused:

VirtualBox indicators focus bug Unity

I’m not sure if this issue is related to a specific GTK or Qt (VirtualBox 5.1.x uses Qt5) version. It occurs on my laptop running Ubuntu 16.10 (64bit), but other Ubuntu flavors as well as other Linux distributions might be affected as well.

The fix / workaround for the VirtualBox focus issue is very simple. All you have to do is open the VirtualBox preferences (File > Preferences) and on the “Input” tab, disable the “Auto Capture Keyboard” option:

VirtualBox Input Preferences

The workaround mentioned above has a drawback though: some keyboard shortcuts will not work in the guest virtual machine while the “Auto Capture Keyboard” option is disabled. For example, using Ctrl + Alt + T to open a new terminal window won’t work in the guest virtual machine. Other shortcuts, such as Ctrl + C, Ctrl + Shift + C, etc. will continue to work though.

Read More

Configure npm To Install Packages Globally Without sudo Using A Script

npm logo

npm is the default package manager for Node.js. It consists of a command line client that integrates with a remote registry, and it makes it easy to install, share and distribute code.

If you’re using npm installed from a repository in Linux (like the official Ubuntu or Node.js repositories), you may have noticed that you can’t install packages globally (“-g”) as a regular user. Many websites mention installing npm packages using sudo, but this messes up some permissions and is not recommended.

The easiest way to get npm to download packages globally without sudo (“npm install -g <package>”) in Linux is to use a script, called npm-g_nosudo, to automatically set everything up.

The script GitHub page mentions that it was tested on Ubuntu 14.04 with Bash, but I don’t see why it wouldn’t work in other Linux distributions.

As an alternative, you can use THESE instructions to set up npm to install packages globally without sudo in Linux.

Here’s what the npm-g_nosudo script does:

  • creates a backup list of your installed npm packages and removes all but npm;
  • then it creates a local directory and configures node to use this for global installs (~/.npm-packages); this (optionally) includes adding the local directory and bin paths to ~/.bashrc or ~/.zsh;
  • it fixes permissions for the ~/.npm directory;
  • and finally, it reinstalls the old packages.

The reason behind publishing this article is to be able to link to it in future posts that mention installing npm packages, to make it easy for users to install them the recommended way – without sudo.

Another way of installing packages with npm in Linux without sudo is by using NVM to install Node.js, instead of a repository.

Configure npm to install packages globally without sudo on Linux (using npm-g_nosudo)

Before proceeding, it’s important to mention that you should never run scripts without understanding what they do. So take a look at the npm-g_nosudo script before running it!

To download the npm-g_nosudo script and run it, use the following commands:

cd && wget https://raw.githubusercontent.com/glenpike/npm-g_nosudo/master/npm-g-nosudo.sh
chmod +x npm-g-nosudo.sh

The script will ask you to choose the install directory – you can press ENTER to use the default directory (~/.npm-packages). The second and final step is to choose if if you want to update ~/.bashrc and ~/.zsh with the new paths – type “y” and press ENTER to do this automatically, or “n” to perform these changes manually.

Once you’re done, remember to source ~/.bashrc or ~/.zsh, depending on what you use (or launch a new terminal):
– for Bash:

source ~/.bashrc

– for Zsh:

source ~/.zsh

Read More

Alternative Global Menu For MATE And Xfce: Vala Panel AppMenu [PPA]

A while back I wrote about TopMenu, a panel plugin that provides global menu (AppMenu) support for MATE, then also included support for Xfce and LXDE.
The problem with TopMenu is that it only partially supports GTK3, it doesn’t support LibreOffice, and with Ubuntu 16.04, it doesn’t support Qt (4 or 5) applications.
Here’s where Vala Panel AppMenu comes in.

Vala Panel AppMenu is a global menu panel applet for Xfce, MATE and Vala panels, which uses unity-gtk-module as its backend, and it works with all the applications supported by Unity’s AppMenu.

Global Menu Linux Mint Vala Panel AppMenu

As a result, Vala Panel AppMenu provides global menu support for GTK2, GTK3, Qt4 and Qt5 applications, as well as applications like Firefox, Thunderbird, Google Chrome / Chromium, and LibreOffice.

For MATE, Vala Panel AppMenu requires MATE Panel built with GTK3 (so for Ubuntu, it requires Ubuntu MATE 16.10 and newer). Its README also mentions that to build Vala Panel AppMenu, you’ll need GTK 3.12 or newer, GLib 2.40 or newer, valac 0.24 or newer and libbamf 0.5.0 or newer.
Here’s Vala Panel AppMenu in action with Chromium, Firefox, Gedit (GTK3), LibreOffice, VLC (Qt5), and Thunar (GTK2): 

Global Menu Xubuntu Xfce Vala Panel AppMenu

Global Menu Xubuntu Xfce Vala Panel AppMenu

Global Menu Xubuntu Xfce Vala Panel AppMenu

Global Menu Xubuntu Xfce Vala Panel AppMenu

Global Menu Xubuntu Xfce Vala Panel AppMenu

Global Menu Xubuntu Xfce Vala Panel AppMenu

Here’s an Ubuntu MATE 16.10 screenshot as well:

Global Menu Ubuntu MATE Vala Panel AppMenu

Vala Panel AppMenu is not perfect though, and I did encounter a few issues in my test:
  • when no window is focused / the desktop is empty, a menu containing “Desktop” and “Files” is displayed by the Vala AppMenu applet. These menu items don’t work, at least in Ubuntu, and using them can cause the Xfce / MATE panel to crash;
  • Qt5 supports the AppMenu feature by default, without using any additional packages (I’m not sure which version introduced this feature), however, there’s a bug with this and Vala AppMenu which causes the global menu for Qt5 applications to be displayed for a few seconds after the app is closed. This doesn’t occur if the appmenu-qt5 package is installed though;
  • MATE only: GTK2 applications have the menu displayed on both the panel and in the application window. If someone can find a way to solve this, please let us know in the comments!;
  • MATE only: there’s no easy way of moving the applet to the desired position, but it can be done using Dconf Editor;
  • there’s no way of changing the global menu font color, and that can be problematic with some themes. For example, the menu font is dark on a dark panel background using the default Xubuntu 16.04 theme (Greybird). This doesn’t occur with Numix GTK theme (which is installed by default in Xubuntu) or Greybird in Xubuntu 16.10.
You may also want to check out the Vala Panel AppMenu issues page on GitHub.

Install and set up Vala AppMenu in Ubuntu (MATE/Xubuntu) or Linux Mint (Xfce) via PPA

If you don’t use Ubuntu or Linux Mint, you can grab the Vala Panel AppMenu source from GitHub.

Arch Linux users can install Vala Panel AppMenu via AUR.

For Ubuntu or Linux Mint, see the instructions below.

1. Install Vala AppMenu.
Vala AppMenu is available in the WebUpd8 MATE and Xfce PPA.
For Ubuntu MATE, the plugin is only available for Ubuntu 16.10, because it requires MATE Panel built with GTK3, and that is only the case for Ubuntu 16.10 and newer.
For Xfce, the Vala AppMenu plugin is available for Xubuntu 16.10 and 16.04, as well as Linux Mint Xfce 18.x.
To add the WebUpd8 MATE and Xfce PPA and update the software sources, use the following commands:
sudo add-apt-repository ppa:webupd8team/mate
sudo apt update

Then, install the Vala AppMenu plugin / applet:

– for Xfce (Xubuntu 16.10, 16.04 / Linux Mint Xfce 18.x):

sudo apt install xfce4-vala-appmenu-plugin unity-gtk3-module unity-gtk2-module appmenu-qt appmenu-qt5

– for MATE (Ubuntu MATE 16.10):

sudo apt install mate-applet-vala-appmenu unity-gtk3-module unity-gtk2-module appmenu-qt appmenu-qt5

2. Disable the menu from being displayed in application windows (so it’s only displayed on the panel; without this, you’ll get double menus, in both the panel and application windows).

2.A. for Xfce, simply run the command below:

xfconf-query -c xsettings -p /Gtk/ShellShowsMenubar -n -t bool -s true
xfconf-query -c xsettings -p /Gtk/ShellShowsAppmenu -n -t bool -s true

2.B. for MATE, you’ll need to edit the ~/.config/gtk-3.0/settings.ini file (if this file doesn’t exist, create it) and in this file, add the following under “[Settings]”:


Here are step by step instructions for doing this. Firstly, create the ~/.config/gtk-3.0/ folder in case it doesn’t exist, by using the following command:

mkdir -p ~/.config/gtk-3.0/

Then open ~/.config/gtk-3.0/settings.ini with Pluma text editor:

pluma ~/.config/gtk-3.0/settings.ini

If this file has a “[Settings]” section, paste under it the following:


If the file is empty, paste the following in this file:


… and save the file.

Unfortunately, for MATE, this will not disable the menu from being displayed in app windows for GTK2 (I mentioned this in the issues section above).

3. Restart the session (logout, then log back in).

4. Add the Vala AppMenu applet to the panel (and how to change its position on the MATE panel).

4.A. For Xfce, right click the panel on which you want to add Vala AppMenu to, and select Panel > Panel Preferences (I prefer this to directly adding the applet to the panel, because it also allows moving it to the desired position), and on the Items tab, click “+” and add “AppMenu Plugin” to the panel:

You can move Vala AppMenu to the desired position on the panel via the Items tab from the Xfce4 Panel Preferences.
If you have TopMenu installed, make sure you don’t mix the two!
4.B. For MATE, right click the panel, select “Add to panel”, then search for “Global Application Menu” and click “Add”:

Unfortunately there’s no easy way of moving the applet to the desired position on the panel. That’s because the Vala Panel AppMenu responds in the same way to both left and right click, and there’s no area to access its context menu.
To change the global menu position on the MATE panel, you’ll need Dconf Editor, which can be installed using the following command:
sudo apt install dconf-editor

Next, launch Dconf Editor, navigate to org > mate > panel > objects and in the “objects” tree, you should see some items called “object-1”, “object-2” and so on. Start from the last object and see which has the “applet-iid” value set to “AppMenuAppletFactory:AppMenuApplet”.

Note: you may have multiple applets (“object-1”, “object-2”, etc.) with the “applet-iid” value of “AppMenuApplet…” – in that case you’ll need to change the settings for the last one (the higher number).

The “position” value represents the number of pixels between the left-hand side of the panel and the applet position. So once you find the right applet, change its position value to suit your needs (try to approximate it, if the other applets are locked, a lower value than the actual position will work in some cases).
In my case, I have a menu, a Firefox launcher, and a separator and I want to move the global menu next to them, so I set the “position” value to “100”:

Global Menu Ubuntu MATE Vala Panel AppMenu

After you change the position, you’ll need to restart the MATE panel to apply the changes (or logout/login). To do this, open a terminal and type:
mate-panel --replace &

5. Optional: enable Vala Appmenu (global menu) for Firefox and Thunderbird.

By default, Vala AppMenu will only display the Thunderbird and Firefox Unity actions (quicklists) on the panel. To enable the full Firefox and Thunderbird menu on the panel, you must launch Firefox and Thunderbird with “UBUNTU_MENUPROXY=0”.

You can do this automatically (by copying the Firefox and Thunderbird .desktop files from /usr/share/applications to ~/.local/share/applications/ so they are not overwritten when they receive updates, and modify the .desktop files there) for both Firefox and Thunderbird, by using the commands below:

mkdir -p ~/.local/share/applications/
cp /usr/share/applications/firefox.desktop ~/.local/share/applications/
sed -i 's/^Exec=/Exec=env UBUNTU_MENUPROXY=0 firefox %u/' ~/.local/share/applications/firefox.desktop
cp /usr/share/applications/thunderbird.desktop ~/.local/share/applications/
sed -i 's/^Exec=/Exec=env UBUNTU_MENUPROXY=0 thunderbird %u/' ~/.local/share/applications/thunderbird.desktop

Undo the changes

Below you’ll find the exact steps required to undo the changes made by following the instructions mentioned above.

1. Remove Vala AppMenu:

sudo apt purge xfce4-vala-appmenu-plugin mate-applet-vala-appmenu

If you are sure (Important! don’t remove these packages if you also use Unity) that the Unity GTK module and AppMenu packages are not used by any other packages on your system, also purge them by using the following command:

sudo apt purge unity-gtk3-module unity-gtk2-module appmenu-qt appmenu-qt5

2. Undo the MATE/Xfce menu disable settings

2.A. For Xfce, use the following commands:

xfconf-query -c xsettings -p /Gtk/ShellShowsMenubar -n -t bool -s false
xfconf-query -c xsettings -p /Gtk/ShellShowsAppmenu -n -t bool -s false

2.B. For MATE, open ~/.config/gtk-3.0/settings.ini with a text editor – the command below uses Pluma to open this file:

pluma ~/.config/gtk-3.0/settings.ini

And from this file, remove the following two lines:


If this file was created by following the instructions in this article (was empty or it didn’t exist before), you can simply remove it by using the following command:

rm ~/.config/gtk-3.0/settings.ini

3. Restart the session (logout, then log back in)

4. If you applied the optional Thunderbird and Firefox tweaks mentioned above, you can undo this step by simply removing their .desktop files from ~/.local/share/applications/. To do this from a terminal, use the following commands:

rm ~/.local/share/applications/firefox.desktop
rm ~/.local/share/applications/thunderbird.desktop

Thanks to WebUupd8 reader omg2090 for the tip and information (check out his comment for how to build this from source and an extra tweak).

Read More

WeatherDesk Changes Your Wallpaper Based On Current Weather Conditions

WeatherDesk is a Python3 tool that allows using a wallpaper that changes based on the weather and optionally, time of day. It supports most Linux desktop environments as well as Windows and Mac.

WeatherDesk weather-based wallpaper Linux

WeatherDesk features:

  • change the background based on the current weather conditions;
  • optionally change the background based on the time of day. This supports 4 variations: day/night, day/evening/night and morning/day/evening/night;
  • supports most Linux desktop environments, including Cinnamon, GNOME, Unity, Xfce, LXDE, LXQt, Pantheon, MATE, and more;
  • automatically detects your current city using ipinfo.io. In case this fails or you simply want to use a different city, you can manually specify the city as a command line argument
  • you can specify the image format, update interval, and more.

KDE Plasma 5 is not listed as supported on the WeatherDesk GitHub page, but looking at the code it appears that it might work. If you test WeatherDesk with Plasma 5, let us know if it works in the comments!
The tool requires a set of images named according to some naming rules, so don’t expect it to alter your current desktop background or anything like that.

WeatherDesk weather-based wallpaper Linux

While WeatherDesk doesn’t come with a built-in wallpaper set, its GitHub page points to a premade set, called FireWatch, available HERE (here’s how it looks), which I’ll use in the instructions below.

The FireWatch wallpaper set doesn’t seem to differentiate between cloudy, normal and windy weather, but you can further tweak it yourself if you want it to be more accurate and your GIMP / Photoshop skills allow it. The set does include proper images for rain, snow, and thunder.

Installing and using WeatherDesk

1. Download / install WeatherDesk

WeatherDesk is available as two simple Python3 scripts that can run from the directory you download them to. You can grab the code from GitHub or simply click here to download the latest code from Git as .tar.gz.

To simplify things, you can use the commands below to download the latest WeatherDesk code from Git, install WeatherDesk in /opt/ and create a symbolic link to its executable in /usr/local/bin/:
sudo apt install wget #in case it's not already installed
wget https://github.com/bharadwaj-raju/WeatherDesk/archive/master.tar.gz -O /tmp/weatherdesk.tar.gz
tar -xvf /tmp/weatherdesk.tar.gz -C /tmp/
sudo mkdir /opt/weatherdesk
sudo cp /tmp/WeatherDesk-master/*.py /opt/weatherdesk/
sudo chmod +x /opt/weatherdesk/WeatherDesk.py
sudo ln -s /opt/weatherdesk/WeatherDesk.py /usr/local/bin/weatherdesk

After this, you can simply use “weatherdesk” in a terminal to run the tool.

2. Download the FireWatch WeatherDesk wallpaper pack

But wait, we’re not done yet! That’s because you’ll also need some wallpapers to change based on current weather conditions and the time of day.

The wallpapers must be named according to some naming rules and placed in the ~/.weatherdesk_walls/ folder for WeatherDesk to pick them up. To make this easy, the WeatherDesk GitHub page points to a pack called FireWatch, which already contains images named according to the WeatherDesk rules.

To create the ~/.weatherdesk_walls folder, download the FireWatch WeatherDesk wallpaper set and extract it into the ~/.weatherdesk_walls folder, you can use the following commands:

mkdir ~/.weatherdesk_walls
wget https://github.com/bharadwaj-raju/FireWatch-WeatherDesk-Pack/archive/master.tar.gz -O /tmp/firewatchpack.tar.gz
tar -xvf /tmp/firewatchpack.tar.gz -C ~/.weatherdesk_walls/ --strip-components=1

3. Run WeatherDesk

That’s it. Now you can simply run “weatherdesk” in a terminal and the app should automatically change your wallpaper based on the current weather conditions and time of day, using the FireWatch wallpaper pack:


If you want to use different wallpapers, you must rename them according to the WeatherDesk naming rules and place them in the ~/.weatherdesk_walls/ folder.

To see all the available WeatherDesk options, run the following command:
weatherdesk --help

For example, to force WeatherDesk to use the weather information for London instead of the automatically detected city, use:
weatherdesk -c london

To get WeatherDesk to also change the wallpaper based on the current time of day, and not just based on the current weather, run it with the “-t” option, like this:
weatherdesk -t

By default this will use the “day / evening / night” variation. To use the “morning / day / evening / night” variation (for more info about this, run “weatherdesk –info“), run it like this:

weatherdesk -t 4

If you want WeatherDesk to change the wallpaper based on current weather conditions every time you login, make sure to add it to your startup applications (in Ubuntu with Unity, launch Startup Applications, click “Add” and use “weatherdesk” as the command).

To report bugs, grab the source code, etc., see the WeatherDesk GitHub page.
Tip: to display the current weather temperature on top of the wallpaper, you could use WeatherDesk in conjunction with Deskweather (I din’t try this, but it could be interesting).

Read More

`Dash To Panel` Is A Cool Icon Taskbar For GNOME Shell

Dash to Panel is a fairly new GNOME Shell extension that moves the dash into the top bar, to achieve a single panel (combined app launchers and system tray) design similar to that of KDE Plasma or Windows 7+.
Dash To Panel GNOME Shell

The extension provides numerous features, including the ability to move the panel to the top or bottom, change the panel size, live window previews, and more.

Since this extension doesn’t create a new panel but instead, it modifies the GNOME Shell Top Bar, it’s compatible with other extensions that change the Top Bar look or behavior. So for instance, while Dash to Panel doesn’t support autohide, you can use the Hide Top Bar extension for this.

Dash to Panel features:

  • move the Application Dash from the Overview into the main panel (top bar);
  • set the panel position to the top or bottom;
  • change the panel size;
  • change the running indicator (dots) position to the top or bottom;
  • set the clock location;
  • the “Show applications” icon can be hidden and its animation can be disabled;
  • displays window previews on hover (optional, enabled by default);
  • option to isolate workspaces (only shows an app icon if it’s on the active workspace, unless it’s a favorite application);
  • configurable click actions (including shift+click, middle+click and shift+middle+click);
  • customize the panel appearance, like the app icon margin, tray font size, icons padding, etc.
Note that while Dash to Panel integrates the system tray into the panel, that’s not the case for the legacy tray. Legacy tray icons continue to be displayed as a drawer in the bottom left corner of the screen (above Dash to Panel, if it’s set to be displayed at the bottom).
Here are some screenshots showing Dash to Panel (and its settings) running in Ubuntu 16.10 with GNOME Shell 3.20:

Dash To Panel GNOME Shell

Dash To Panel GNOME Shell

Dash To Panel GNOME Shell

Dash To Panel GNOME Shell

Dash To Panel GNOME Shell

Dash To Panel GNOME Shell

Dash To Panel GNOME Shell
The application menu that’s usually displayed on the GNOME Shell Top Bar is no longer displayed when using Dash to Panel. 
To get access to this menu, it’s recommended you disable displaying the applications menu in GNOME Tweak Tool (set Top Bar > Show Application Menu to OFF) so the menu is displayed as a button in the top left window corner:

A bug report regarding this was submitted to GitHub, and it looks like a way to integrate the GNOME AppMenu with Dash to Panel might be available in the future.
Another feature that’s not available in Dash to Panel is multi-monitor support. This was already implemented, but has not been merged so far.
I should also mention that using this extension on my pretty old laptop (Intel graphics) results in severe lag when accessing the activities/applications. However, this issue does not occur after disabling the “Animate Show Applications” feature from the Dash to Panel settings (Behavior tab). A bug report regarding this has already been submitted.

Install Dash to Panel

Dash to Panel should work with GNOME 3.18+ and it can be installed by using the GNOME Shell Extensions website.

Tip: see how to get Chrome to support installing GNOME Shell Extensions from extensions.gnome.org, HERE.
For more information, source code, bug reports, etc., see the Dash to Panel extension GitHub page.

via WOGUE @ Google+

Read More

Add A Searchable Command Palette To Any GTK3 Application Using Plotinus

Plotinus is a library that adds a searchable command palette to any GTK+ 3 application, similar to the Atom and Sublime Text Command Palette feature (or Unity HUD).

Plotinus with Gedit

To use it, press Ctrl + Shift + P and you can easily find the action you’re looking for by typing a few letters, without having to go through the application menus. The keyboard shortcut cannot be changed, unless you build Plotinus from source.

You don’t have to make any modifications to GTK+ 3 applications to use this, you’ll only need Plotinus, which can be used either for some specific applications, or globally, for all GTK+ 3 applications.
Since I’m not sure if it works properly with all GTK+ 3 applications (I didn’t encounter any issues in my test though), the Plotinus package from the WebUpd8 PPA doesn’t activate Plotinus globally, but you can do this manually if you wish.

Installing and using Plotinus

For Ubuntu 16.10 or 16.04 / Linux Mint 18 (I was unable to build it for Ubuntu 14.04), you can install Plotinus by using the main WebUpd8 PPA. Add the PPA and install Plotinus using the following commands:
sudo add-apt-repository ppa:nilarimogard/webupd8
sudo apt update
sudo apt install libplotinus

Alternatively, you can download the deb from HERE.

For how to install Plotinus in other Linux distributions, see its installation section on GitHub.

To use Plotinus for an application, use the following command:

GTK3_MODULES=/path/to/libplotinus.so application

where “application” is the application executable and /path/to/libplotinus.so is the exact path to libplotinus.so. If you’ve used the WebUpd8 PPA, the path is:

  • 32bit: /usr/lib/i386-linux-gnu/libplotinus/libplotinus.so
  • 64bit: /usr/lib/x86_64-linux-gnu/libplotinus/libplotinus.so

For example, to run Gedit with Plotinus enabled on a 64bit system (assuming Plotinus was installed via the WebUpd8 PPA), use the following command (make sure no Gedit instances are currently running):
GTK3_MODULES=/usr/lib/x86_64-linux-gnu/libplotinus/libplotinus.so gedit

You can either run this command from a terminal, or edit the application .desktop file and change the “Exec” line to this command.

To enable Plotinus globally (for all GTK+ 3 applications), open /etc/environment with a text editor (as root) and at the end of this file, paste the following:


where “/path/to/libplotinus.so” is the exact path to libplotinus.so (if you’ve installed Plotinus from the WebUpd8 PPA, see the exact path for 32bit and 64bit above). Then restart the session (logout/login).

To download the source, report bugs, etc., see the Plotinus GitHub page.

Also see: How To Get A Unity-Like HUD (Searchable Menu) In Xubuntu, Ubuntu MATE, Linux Mint, More

Read More

Switch Between Multiple Lists Of Apps Pinned To Unity Launcher With `Launcher List Indicator`

Launcher List Indicator is a simple AppIndicator that makes it easy to switch between multiple lists of Unity Launcher icons (apps pinned to the launcher).

Launcher List Indicator

The indicator allows saving applications that are pinned to the Unity launcher as a list that can later be restored from the its menu. 
This is useful if you often use the same computer for multiple purposes. For instance, you can have a profile with applications that you only use for work, another profile with for web-related stuff, and another one for gaming, and easily switch between them using Launcher List Indicator.

Launcher List Indicator is pretty basic. It allows switching between profiles (obviously), saving and removing profiles. There are no settings, and it doesn’t ship with a monochrome panel icon (you can change its icon if you want, by replacing the “indicator-icon.png” file – if you’ve used the PPA package, this can be found in /opt/launcher-list-indicator/).

Install Launcher List Indicator

To install Launcher List Indicator, you can use the main WebUpd8 PPA. To add the PPA and install the indicator in Ubuntu, use the following commands:
sudo add-apt-repository ppa:nilarimogard/webupd8
sudo apt update
sudo apt install launcher-list-indicator

If you don’t want to add the PPA, you can download the deb from HERE.

Once installed, launch it from Dash. 
To have Launcher List Indicator start automatically on login, you’ll need to add it to startup. To do this, launch “Startup Applications” from Dash, click “Add”, enter anything you want under “Name”, and use “launcher-list-indicator” in the “Command” field.

Report any bugs you may find @ GitHub.

More Unity tools / tweaks:

Read More

How To Completely Disable Mouse Acceleration In Linux

Some desktop environments don’t provide a way to change the mouse acceleration (GNOME and Unity for instance), and even for those that do (like Cinnamon), you can’t completely turn it off. Here’s how to completely disable mouse acceleration in Linux (for Xorg).

Disabling mouse acceleration is useful for FPS gaming. Mouse acceleration makes the pointer movement depend on the speed with which you move the mouse, accelerating as you move it faster. So moving the mouse across the same distance can have different results, based on movement speed. In FPS games, this can make aiming difficult.

With mouse acceleration disabled, the movement of the pointer is the same as the movement of the mouse, and it doesn’t change based on the movement speed. As a result, your aim should be more accurate in first-person shooters.

To completely disable mouse acceleration, create a file called “50-mouse-acceleration.conf” in xorg.conf.d. The path to xorg.conf.d can vary depending on the Linux distribution you use. For instance, in Ubuntu, Linux Mint, and derivatives, it’s /usr/share/X11/xorg.conf.d/. On Arch Linux, it’s /etc/X11/xorg.conf.d/.

To open an empty 50-mouse-acceleration.conf file in /usr/share/X11/xorg.conf.d/ with Nano (command line text editor; should be installed by default in most Linux distributions), use the following command:

sudo nano /usr/share/X11/xorg.conf.d/50-mouse-acceleration.conf

And in this file, paste the following:

Section "InputClass"
Identifier "My Mouse"
MatchIsPointer "yes"
Option "AccelerationProfile" "-1"
Option "AccelerationScheme" "none"
Option "AccelSpeed" "-1"
Then save the file (to save the file in Nano, use Ctrl + o, then press Enter; to exit, use Ctrl + x). Note that the section just needs an identifier, but the actual name doesn’t matter, so you don’t have to replace “My Mouse” with anything.
Once you’re done, restart the session (logout/login). That’s it!
Using this, the Touchpad acceleration is left unchanged.

You may also be interested in:

via Arch Linux wiki; image from Wikipedia

Read More

How To Prevent The Super Key From Opening Dash On Top Of Fullscreen Windows (Ubuntu /w Unity Only)

Unity Dash on top of fullscreen game

In Ubuntu (Unity), the Super (Windows) key is used to open Unity Dash. Accidentally pressing the Super key when playing fullscreen games can be quite annoying, because Dash covers quite a bit of the screen, so you can’t see what’s going on, and it also switches the keyboard input from the game to Unity.

If you’ve gotten used to using the Super key to open Dash and don’t want to change it, you can use a Python script, created by Sergiy Kolodyazhnyy for AskUbuntu, which automatically disables the Super key from opening Unity Dash, if there are any fullscreen windows. Note that the script has only been tested in Ubuntu 16.04.

The script does not disable Super key combinations, so for instance, Super + L will continue to lock the screen, etc. Only opening the Dash is disabled, which is triggered by pressing the Super key alone.

You can check out the script code HERE.

To download the script and install it in /usr/local/bin, use the following commands:
sudo apt install wget
wget http://raw.githubusercontent.com/SergKolo/sergrep/master/disable_super_key.py -O /tmp/disable_super_key.py
sudo install /tmp/disable_super_key.py /usr/local/bin/

Update: since the Alt key triggers the HUD by default, which causes the same issues as the Dash, I modified Sergiy’s Python script to also disable the Alt key while there are fullscreen windows. You can check out the script code HERE.

To install the modified script that disables both Alt and Super keys from opening Dash and Hud when a fullscreen window is focused, use the following commands:
sudo apt install wget
wget https://raw.githubusercontent.com/hotice/webupd8/master/disable_super_key.py -O /tmp/disable_super_key.py
sudo install /tmp/disable_super_key.py /usr/local/bin/

Once installed, you’ll need to add the script to startup.

To do this, open Startup Applications from Unity Dash, click “Add”, enter anything you want under “Name”, and for “Command”, use:

If you’ve installed it in a different location, click “Browse” and select the disable_super_key.py script. That’s it!

If you prefer to change the Dash keyboard shortcut, so it doesn’t uses the Super key, install CompizConfig Settings Manager (CCSM):
sudo apt install compizconfig-settings-manager
Then open CCSM, click on Ubuntu Unity Plugin, and on the Launcher tab, assign a different shortcut for “Key to show the Dash, Launcher and Help Overlay”.

Read More

Add Recently Accessed Files As Quicklists To Apps Pinned To Unity Launcher With `Ubuntu RecentQuicklists`

Ubuntu RecentQuicklists is a Python script that adds recently accessed files as quicklists (right click menu) to applications pinned to the Unity Launcher.
Ubuntu RecentQuicklists

The script should work with any application that handles files, as long as it has a desktop file under /usr/share/applications/. Among the applications confirmed to work with Ubuntu RecentQuicklists are LibreOffice (Writer, Calc, Impress), Gedit, Firefox, Google Chrome, VLC, Clementine, Evince, Atom, and others.

You may want to check out the Ubuntu RecentQuicklists wiki for compatibility information and FAQ.

The tool allows some customization via its configuration file (called “urq.conf” – it should be available in the script folder after running it for the first time!), such as:
  • maxage – only show files that were accessed in the last <maxage value> days;
  • showfullpath – when set to “True”, it displayes the file path and name, and when set to “False”, it only displays the file name;
  • maxentriesperlist – the maximum number of recent files to display in a single quicklist;
  • startupsplash – show or hide a notification when Ubuntu RecentQuicklist starts;
  • more.

Here’s another screenshot, showing recent quicklists for LibreOffice Impress, with “showfullpath” set to “True”:

Ubuntu RecentQuicklists

It’s important to mention that the recently used files show up as quicklists only for the apps that were pinned to the Unity launcher before running Ubuntu RecentQuicklists.

Also, the script doesn’t detect moved, deleted, or renamed files, and in such cases, the file is removed from the quicklist only after the user clicks it. When this occurs, a notification is displayed.

Download and use Ubuntu RecentQuicklists

To use it, extract the downloaded archive, make “ubuntu-recentquicklists.py” executable, either via right click > Properties > Permissions > Allow executing file as program, or from the command line:

chmod +x /path/to/ubuntu-recentquicklists.py

(where “/path/to/ubuntu-recentquicklists.py” is the path to ubuntu-recentquicklists.py, e.g.: ~/Downloads/ubuntu-recentquicklists.py)

And then run ubuntu-recentquicklists.py, either from your file manager (if you use Nautilus, you need to change some settings to be able to double click executables to run them), or from the command line:


To automatically start Ubuntu RecentQuicklists when you login, open “Startup Applications” from Dash, click “Add”, use whatever you want for its name, and for “Comamnd”, click “Browse”, and select the ubuntu-recentquicklists.py file.

More Unity tweaks:

Read More