Here’s a short guide showing you how to hide mounted drives from the Ubuntu Dock in Ubuntu 19.10 and 20.04 LTS.
Icons for mounted drives on the Ubuntu Dock appear on the Ubuntu Dock by default. This features makes it easy to access removable drives, SD cards, USB thumb sticks, and remote mounts regardless of which app you’re currently using.
You insert a USB stick, an SD card and, or external drive and —BAM! An icon for it instantly appears in the Ubuntu Dock.
Using the relevant dock icon you can then instantly open the connected drive in the Nautilus file manager, as well as right-click on a dock icon to access the relevant Safely Remove
option.
But not everyone needs or wants instant access to their mounted drives.
And if multiple different removable drives are attached at any one time — think: an SD card, external USB drive, and a Google Drive mount — the dock can get rather crowded quite quickly.
Thankfully you can turn the feature off and stop mounted drives from showing up in the Ubuntu Dock. Access isn’t nuked entirely; can continue to access your removable drives using the Nautilus file manager.
Hide Mounted Drives
You can hide mounted drives in Ubuntu Dock using the dconf
editor tool (GUI) or using the terminal (CLI).
I recommend using the command line option as there’s less chance of accidentally disabling/enabling other hidden features.
Open a new Terminal window (Ctrl
+ Alt
+ t
) and run this command:
gsettings set org.gnome.shell.extensions.dash-to-dock show-mounts false
The change will take effect instantly and mounted drives showing on the Ubuntu Dock will instantly disappear from view.
If you change your mind and want to re-enable mounted drives on the Ubuntu Dock in future, just rerun the same command, omitting the ‘false’ switch at the end like so:
gsettings set org.gnome.shell.extensions.dash-to-dock show-mounts true
You can access the same setting via a GUI if you install the dconf-editor
tool and navigate to the org > gnome shell > extensions > dash-to-dock
page, switching the show-mounts
toggle to the off position.
Tip Also works in Dash to Dock
Because the Ubuntu Dock is based on the Dash to Dock extension for the GNOME Shell desktop environment the steps mentioned in this work with the regular Dash to Dock gnome extension too,
For now it is not possible to whitelist mounts so that only specific drives show up in the Dock. You can either hide mounted drives from the Ubuntu Dock entirely, or not at all.
How To
dash to dock
Ubuntu 19.10
ubuntu basics
ubuntu dock