23

I want to change the date/time format on the top panel to a format close to RFC 3339 / ISO 8601, like one of these:

%F %T → 2013-06-24 16:13:00

%F %a %T → 2013-06-24 Mon 16:13:00

%A %F %T → Monday 2013-06-24 16:13:00

I know Unity has a preference somewhere hidden away in dconf, this is how I did it in Unity, but I can't find such a preference for Gnome 3 shell. Preferably, I'd also like to set one of these as my system-wide date/time locale preference.

Braiam
  • 69,112

6 Answers6

15

Open a terminal and set

gsettings set org.gnome.desktop.interface clock-show-date true

YMMW - this did work for me on Fedora 19.

Martin
  • 215
11

I was ultimately able to achieve my exactly desired format using a GNOME extension made by Daniel Khodabakhsh. Thank you Daniel!

I found that here: https://github.com/Daniel-Khodabakhsh/datetime-format

Screenshot: enter image description here

Format: %A | %m-%d-%G | %I:%M %p

Lonnie Best
  • 2,244
5

In addition to what Martin says, the following worked for me on Ubuntu 14.04, where dconf-editor didn't:

gsettings set org.gnome.desktop.interface clock-show-date true
gsettings set org.gnome.desktop.interface clock-show-seconds true
seddy
  • 191
4

You can try one of these three extensions:

  • Full Clock

    enter image description here Replaces the default clock with a complete one showing time, date and week day

  • Full Clock 2

    enter image description here Replaces the default clock with a one showing date, week, day of week and time.

  • Format Clock (development discontinued, but apparently working fine in 3.16)

    enter image description here Change top panel clock format.

    It says the develpmont has been discontinued, but I tested it, manually editing metadata.json to include 3.18, and it works:

    enter image description here

muru
  • 207,228
2

Partial answer:

Although it doesn't look like the panel clock is easy to format, the calendar menu opened by clicking on it is very easy. Here's a quick hack:

$ sudo vim /usr/share/gnome-shell/js/ui/dateMenu.js

(vim or any other text editor.)

Search for ‘B %d, %Y’, and replace with ‘F’. Save. Press Alt+F2, r, Enter, to restart the shell.

Searching the parent directory reveals a few others that might be worth experimenting with:

$ rgrep -I '%B' /usr/share/gnome-shell/js/ui/

but unfortunately, searching for the abbreviated month name in the panel clock returns nothing here:

$ rgrep -I '%b' /usr/share/gnome-shell/

Any changes to these file will probably be overwritten by updates to Gnome, and you may want to keep the originals of files you edit (sudo mv [name].js [name].js.orig).

-1

On Ubuntu 19.10:

gsettings set org.gnome.desktop.interface clock-show-weekday true
gsettings set org.gnome.desktop.interface clock-show-seconds true

etc.

Or, run

dconf-editor

and go to org.gnome.desktop.interface. You will find clock-show-weekday, clock-show-seconds, clock-show-date and others.

Eliah Kagan
  • 119,640
G. S.
  • 115