Skip to content

Commit

Permalink
Merge branch 'release/4.9.1'
Browse files Browse the repository at this point in the history
  • Loading branch information
martin-ueding committed Feb 24, 2017
2 parents a06d751 + 42ce39e commit 3fa581a
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 1 deletion.
6 changes: 6 additions & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,12 @@
Changelog
#########

v4.9.1
Released: 2017-02-24 22:35:30 +0100

- Update documentation
- Improve determination of the username that is logged in using X.

v4.9.0
Released: 2017-02-19 18:03:31 +0100

Expand Down
1 change: 1 addition & 0 deletions doc/guides/getting-started.rst
Original file line number Diff line number Diff line change
Expand Up @@ -184,6 +184,7 @@ Needed Program Debian package Arch Linux package For
============== ======================== ================== =========================================
gsettings libglib2.0-bin glib2 subpixel anti-alias order with GNOME/XFCE
kvkbd kvkbd kvkbd virtual keyboard
lsusb usbutils usbutils docking detection with a USB device
nmcli network-manager networkmanager changing wifi
pactl pulseaudio-utils libpulse volume control when docking
xbacklight xbacklight xorg-xbacklight adjusting brightness
Expand Down
7 changes: 6 additions & 1 deletion tps/hooks.py
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,12 @@ def postdock(state, config):
def get_graphicsl_user():
pattern = re.compile(r'\(:0(\.0)?\)')

lines = tps.check_output(['who', '-u'], logger).decode().split('\n')
lines = tps.check_output(['who', '-u'], logger)\
.decode().strip().split('\n')
# If there is a single user, choose them.
if len(lines) == 1:
return lines[0].split()[0]
# Otherwise, search for a user description that matches the regex.
for line in lines:
m = pattern.search(line)
if m:
Expand Down

0 comments on commit 3fa581a

Please sign in to comment.