X-Git-Url: https://iankelling.org/git/?a=blobdiff_plain;f=switch-mail-host;h=8d4072b72e1dc29b823a535db168f5a11c41b4d5;hb=f0a35267f28e274ef3c2f63ffc20a26ca864e37c;hp=9315807d6ca00196574a06d967158c951f7becfc;hpb=dd2ab37728aeaf8b887d128c50601fb5d9bd8841;p=distro-setup diff --git a/switch-mail-host b/switch-mail-host index 9315807..8d4072b 100755 --- a/switch-mail-host +++ b/switch-mail-host @@ -125,8 +125,15 @@ for ((i=0; i<10; i++)); do sleep 1 if [[ i == 9 ]]; then warn="WARNING!!! failed to kill arbtt-capture" - fi - done + fi +done +for ((i=0; i<10; i++)); do + $new_shell killall arbtt-capture || break + sleep 1 + if [[ i == 9 ]]; then + warn="WARNING!!! failed to kill arbtt-capture" + fi +done $new_shell bash -s <<'EOF' @@ -218,6 +225,6 @@ if $restore_old_btrbk; then $old_shell sudo systemctl start btrbk.timer fi -$new_shell arbtt-capture --sample-rate=10 & +$new_shell DISPLAY=:0 arbtt-capture --sample-rate=10 & echo $warn