6

My goal

I want to set a shortcut to open the Select Network dialog that opens from the top left system menu. The graphic way to open it is to click on the top left corner, then on your network, then on "Select Network", like below.

Graphic way The dialog I want to open

What I've tried

  • I've seen this post that is kind of a duplicate but I want to set a shortcut and not just handle my wifi I command line. How do I run GNOME Wi-Fi selection dialog through terminal with command line?

    So I know I can run

    gnome-control-center wifi
    

    But this leads to the control center and not to the little Pop-up I want to access.

  • I have also tried to write a script with xdotool but this is inconsistent as it needs some sleep because I pass through the super+F10 shortcut and then move in the top bar to reach the Select Network item.

    The script looks like that but I don't really think it's relevant.

    #! /bin/sh
    xdotool key super+F10
    sleep 0.6
    xdotool key Right
    xdotool key Right
    xdotool key Right
    xdotool key Right
    xdotool key Right
    sleep 0.3
    xdotool key Down
    xdotool key Down
    xdotool key Down
    xdotool key Return
    xdotool key Down
    xdotool key Return
    

Config

Memory: 7,7 GiB,
Processor: Intel® Core™ m3-7Y30 CPU @ 1.00GHz × 4,
Graphics: Mesa Intel® HD Graphics 615 (KBL GT2),
Disk Capacity: 256,1 GB

OS: Ubuntu 20.04 LTS, 64 bit.
GNOME version: 3.36.2

pomsky
  • 68,507
Luuudo
  • 61

1 Answers1

0

You probably are looking for text-based tools like nmcli or nmtui, they generally ship with most distros and it's part of the NetworkManager package. They both have the hability to provide some sort of a shortcut after creating the connection.

Marco
  • 111