commit 55449b6f0a93b51dc5d79956b97ccbc0c7919be5
parent 3bf020cbbf66d4ea5968d390f0b56183c5cf557a
Author: pyratebeard <root@pyratebeard.net>
Date: Wed, 17 Apr 2024 12:23:50 +0100
updates
Diffstat:
1 file changed, 9 insertions(+), 0 deletions(-)
diff --git a/programming/nubbins.md b/programming/nubbins.md
@@ -21,5 +21,14 @@ find [top processes][] sorted by mem or cpu usage
ps -eo pid,ppid,cmd,%mem,%cpu --sort=-%mem | head
```
+## tmux ssh
+use tmux window name to ssh (.bashrc function example)
+```
+ssh() {
+ [ $# -eq 0 ] && \
+ /usr/bin/ssh $(tmux display-message -p '#W') || \
+ /usr/bin/ssh $*
+```
+
[zombie processes]: https://www.howtogeek.com/119815/htg-explains-what-is-a-zombie-process-on-linux/
[top processes]: https://tecmint.com/find-linux-processes-memory-ram-cpu-usage