by mcint · 2y ago · 0 comments
In .ssh/rc:
if [ -n "$DOMAIN" ]; then
# ... create socket & report to user
clean_socket(){ rm /tmp/test.dev.tld.socket; }
trap clean_socket EXIT INT HUP;
fiI combined this infinite loop in ssh rc and a -T and a simple command "echo hello" in my client function and now it prints out the link to visit, hangs infinitely until I close it or it gets closed, and cleans itself up.
This just took the level of hackishness to new heights and I love it.