5

How to remove clock from the top panel in gnome-shell? enter image description here

Laurynas
  • 150

4 Answers4

8

It is possible by creating an extension.

mkdir -p ~/.local/share/gnome-shell/extensions/Disable_Clock@ocelot
cd  ~/.local/share/gnome-shell/extensions/Disable_Clock@ocelot

Make a metadata.json file.

gedit metadata.json

Cut following code, and Paste into the editor ,and Save.

{"shell-version": ["3.2"], "uuid": "Disable_Clock@ocelot", "name": "Disable Clock", "description": "Disable Clock from the top of panel"}

Make an extension.js file.

gedit extension.js

Cut following code, and Paste into the editor ,and Save.

const St = imports.gi.St;
const Main = imports.ui.main;

function init(meta) {
}

function enable() {
    Main.panel._centerBox.remove_actor(Main.panel._dateMenu.actor);
}

function disable() {
    Main.panel._centerBox.add_actor(Main.panel._dateMenu.actor);
}

Restart gnome-shell and Turn on "Disable Clock" extension by gnome-tweak-tool

wildjiji
  • 216
2

Hide the clock in your current session with this command:

dbus-send --session --type=method_call --dest=org.gnome.Shell /org/gnome/Shell org.gnome.Shell.Eval string:'Main.panel._dateMenu.actor.hide();'
1

Press Alt+Right click the clock, there should be an entry saying Remove from panel.

Bruno Pereira
  • 73,643
0

At teminal type the following:

sudo apt-get remove indicator-datetime
all4naija
  • 1,554