Archived
1
0

1 Commits
0.0.7 ... 0.0.8

Author SHA1 Message Date
1dfd3f090f Add status command 2025-08-24 05:08:13 +02:00

View File

@@ -38,15 +38,15 @@ case ${1} in
esac esac
function showProxyStatus() { function showProxyStatus() {
echo -e "Port\tProxy" if [ -d /tmp/ssh-proxy-"${USER}" ] && [ "$(find /tmp/ssh-proxy-"${USER}" -maxdepth 0 -empty -exec echo 1 \;)" == "" ]; then
if [ -d /tmp/ssh-proxy-"${USER}" ]; then echo -e "Port\tProxy"
if [ "$(find /tmp/ssh-proxy-"${USER}" -maxdepth 0 -empty -exec echo 1 \;)" == "" ]; then for FILE in /tmp/ssh-proxy-"${USER}"/*; do
for FILE in /tmp/ssh-proxy-"${USER}"/*; do PORT=$(basename "${FILE}")
PORT=$(basename "${FILE}") PROXY=$(grep 'PROXY=' "${FILE}" | sed 's/PROXY=//')
PROXY=$(grep 'PROXY=' "${FILE}" | sed 's/PROXY=//') echo -e "${PORT}\t${PROXY}"
echo -e "${PORT}\t${PROXY}" done
done else
fi echo "No open proxy"
fi fi
} }