This is an automated email from the git hooks/post-receive script. x2go pushed a commit to branch feature/openbox in repository live-build-x2go. commit 9a2d1d4b0296cffd179f8bb7bbf7e95bed1d6004 Author: Stefan Baur (BAUR-ITCS) <kontakt@baur-itcs.de> Date: Sun Feb 4 16:49:03 2018 +0100 added active audio profile output, moved audio block to end of file so pulseaudio has more time to start up --- .../lib/live/config/2900-x2go-thinclientconfig | 51 +++++++++++----------- 1 file changed, 26 insertions(+), 25 deletions(-) diff --git a/config/includes.chroot/lib/live/config/2900-x2go-thinclientconfig b/config/includes.chroot/lib/live/config/2900-x2go-thinclientconfig index de5b03e..bec11dd 100755 --- a/config/includes.chroot/lib/live/config/2900-x2go-thinclientconfig +++ b/config/includes.chroot/lib/live/config/2900-x2go-thinclientconfig @@ -31,31 +31,6 @@ AUDIOOUT=\$(sed -e 's/ \([^ ]*\)=/\n\1=/g' -e 's/\([^=]["'"'"']\) /\1\n/g' -e 's awk -F'=' ' /^audioout=/ { print \$2 }' | \ tr -dc 'a-zA-Z0-9.:_\-@|') -if [ -n "\$AUDIOOUT" ] ; then - if [ "\$AUDIOOUT" = "list" ] ; then - echo -en "\n\$(date +'%F | %T | ')'\$0': Available audio outputs:" | tee -a /dev/tty8 - AUDIOOUTPUTS=\$( for CARD in \$(pacmd list-cards | grep -A1 index | awk -F '[<> \t]' ' \$2 == "name:" { print \$4 }'); do - pacmd list-cards | \ - more +/"\$CARD" | \ - grep -m 1 "\$CARD" -A100000 | \ - more +/"profiles:" | \ - grep -m 1 -B10000 "active profile:" | \ - grep -A10000 "profiles" | \ - grep "\W\Woutput:" | \ - grep -v "active profile:" | \ - awk -F'[+:]' '{gsub("\t","",\$1) ; print "\"'\$CARD'|" \$1 ":" \$2 "\""} '; - done | \ - sort -u ) - for AUDIOOUTPUT in \$AUDIOOUTPUTS; do - echo -en "\n\$(date +'%F | %T | ')'\$0': \$AUDIOOUTPUT" | tee -a /dev/tty8 - done - elif (echo "\$AUDIOOUT" | grep -q '^[^|]*|[^|]*\$') ; then - $(echo "\$AUDIOOUT" | sed -e 's/^/pacmd set-card-profile "/' -e 's/\$/"/' -e 's/|/" "/') - else - : # NOP - fi -fi - # additional variable instead of "case \$(...) in", as we need the value again later on XRANDRCMDTAINTED=\$(sed -e 's/ \([^ ]*\)=/\n\1=/g' -e 's/\([^=]["'"'"']\) /\1\n/g' -e 's/ \([^ "'"'"']\)/\n\1/g' /proc/cmdline | awk -F '=' '\$1 == "xinerama" { print \$2 }') @@ -261,6 +236,32 @@ if [ -n "\$BLANKINGTIME" ]; then fi fi +if [ -n "\$AUDIOOUT" ] ; then + if [ "\$AUDIOOUT" = "list" ] ; then + echo -en "\n\$(date +'%F | %T | ')'\$0': Available audio outputs:" | tee -a /dev/tty8 + AUDIOOUTPUTS=\$( for CARD in \$(pacmd list-cards | grep -A1 index | awk -F '[<> \t]' ' \$2 == "name:" { print \$4 }'); do + pacmd list-cards | \ + more +/"\$CARD" | \ + grep -m 1 "\$CARD" -A100000 | \ + more +/"profiles:" | \ + grep -m 1 -B10000 "active profile:" | \ + grep -A10000 "profiles" | \ + grep "\W\Woutput:" | \ + grep -v "active profile:" | \ + awk -F'[+:]' '{gsub("\t","",\$1) ; print "\"'\$CARD'|" \$1 ":" \$2 "\""} '; + done | \ + sort -u ) + for AUDIOOUTPUT in \$AUDIOOUTPUTS; do + echo -en "\n\$(date +'%F | %T | ')'\$0': \$AUDIOOUTPUT" | tee -a /dev/tty8 + done + echo -en "\n\$(date +'%F | %T | ')'\$0': \$(pacmd list | 'grep active profile')" | tee -a /dev/tty8 + elif (echo "\$AUDIOOUT" | grep -q '^[^|]*|[^|]*\$') ; then + $(echo "\$AUDIOOUT" | sed -e 's/^/pacmd set-card-profile "/' -e 's/\$/"/' -e 's/|/" "/') + else + : # NOP + fi +fi + eval \$THROTTLINGCOMMAND x2goclient --thinclient --no-session-edit --no-menu --maximize --add-to-known-hosts --haltbt --read-exports-from=/home/user/export \$LDAPPARAMS \$SESSIONFROM \$BACKGROUND \$BRANDING \$STARTSESSION XSESSION -- Alioth's /home/x2go-admin/maintenancescripts/git/hooks/post-receive-email on /srv/git/code.x2go.org/live-build-x2go.git