X-Git-Url: https://iankelling.org/git/?a=blobdiff_plain;f=brc2;h=05de0a3f1cf93cbc19db5213794c83b6a129807f;hb=1f027ea146ea6c62002a8f67f831273a5c431b52;hp=de12005348a0efa2fad4e0e1f2952902cb4d912d;hpb=ef3bbffe6d2a08ebd735ba4f09c7bd0fbea585a0;p=distro-setup diff --git a/brc2 b/brc2 index de12005..05de0a3 100644 --- a/brc2 +++ b/brc2 @@ -172,7 +172,7 @@ slemacs() { sle() { # sl emacs local f=/home/iank/.emacs.d/init.el - sl --sl-test-cmd ". /etc/os-release ; printf %s \${VERSION//[^a-zA-Z0-9]/}; test -e $f && stat -c%Y $f" --sl-test-hook slemacs "$@" + sl --sl-test-cmd "sed -rn '/^VERSION=/{s/^.*=//;s/[^[:alnum:]]//gp}' /etc/os-release; test -e $f && stat -c%Y $f" --sl-test-hook slemacs "$@" } ccomp ssh sle @@ -2639,7 +2639,7 @@ wgkey() { host-info-all() { host-info-update bindpushb8 - ssh li.b8.nz conflink + ssh iank@li.b8.nz conflink wrt-setup } @@ -2650,7 +2650,7 @@ host-info-all() { host-info-update() { local -A vpn_ips host_ips host_macs nonvpn_ips all_ips - local -a root_hosts nonroot_hosts + local -a root_hosts nonroot_hosts host_usbs # the hosts with no mac root_hosts=( bk je li b8.nz ) @@ -2690,9 +2690,11 @@ host-info-update() { else nonroot_hosts+=($host ${host}i) fi - host_ips[$host]=$ip - host_macs[$host]=$mac + if [[ $mac ]]; then + host_macs[$host]=$mac + fi + done