Recovered lost code from other libraries
This commit is contained in:
13
bash/thismux.sh
Normal file
13
bash/thismux.sh
Normal file
@@ -0,0 +1,13 @@
|
||||
thismux() {
|
||||
dir="$(pwd)"
|
||||
# Search upwards for `.run/thismux.sock`
|
||||
while [ "$dir" != "/" ]; do
|
||||
if [ -d "$dir/.run" ]; then
|
||||
tmux -S "$dir/.run/thismux.sock" "$@"
|
||||
return
|
||||
fi
|
||||
dir="$(dirname "$dir")"
|
||||
done
|
||||
echo "No .run found in any parent directory."
|
||||
return 1
|
||||
}
|
||||
Reference in New Issue
Block a user