Skip to content

Instantly share code, notes, and snippets.

@jpouellet
Last active February 19, 2023 19:25
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save jpouellet/95a4ec46a149ea5d8a6ec0927772cfb4 to your computer and use it in GitHub Desktop.
Save jpouellet/95a4ec46a149ea5d8a6ec0927772cfb4 to your computer and use it in GitHub Desktop.
Enable/disable WIFI in Qubes via keyboard shortcut

To add keyboard shortcut, in dom0:

$ sudo install -m 755 /usr/local/bin/qubes-wifi-toggle ./qubes-wifi-toggle.sh
$ xfconf-query -c xfce4-keyboard-shortcuts -p /commands/custom/XF86WLAN -s qubes-wifi-toggle
#!/bin/sh
exec qvm-run sys-net '[ X"$(nmcli radio wifi)" = Xdisabled ] && x=on || x=off; nmcli radio wifi $x'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment