Skip to content

Instantly share code, notes, and snippets.

@santileortiz
Created May 14, 2018 08:26
Show Gist options
  • Save santileortiz/901c57c8583ebbc3f2a03319e65a6b3f to your computer and use it in GitHub Desktop.
Save santileortiz/901c57c8583ebbc3f2a03319e65a6b3f to your computer and use it in GitHub Desktop.
Script to setup a virtual terminal to be able to run a debug version of gnome-shell in Ubuntu
gnome_session=$(pgrep --full -u $USER gnome-session-binary.*ubuntu)
eval export $(sed 's/\o000/\n/g;' < /proc/$gnome_session/environ | grep DISPLAY)
eval export $(sed 's/\o000/\n/g;' < /proc/$gnome_session/environ | grep XAUTHORITY)
eval export $(sed 's/\o000/\n/g;' < /proc/$gnome_session/environ | grep XDG_SESSION_TYPE)
eval export $(sed 's/\o000/\n/g;' < /proc/$gnome_session/environ | grep DBUS_SESSION_BUS_ADDRESS)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment