mirror of
https://github.com/dustinkirkland/byobu.git
synced 2025-02-20 08:58:53 -08:00
* usr/lib/byobu/users:
- Handle stderr for ps, e.g. unsupported options - Fix trailing '#' sign
This commit is contained in:
parent
b10c7b6f65
commit
768f08712d
3
debian/changelog
vendored
3
debian/changelog
vendored
@ -50,6 +50,9 @@ byobu (5.128) unreleased; urgency=medium
|
||||
- Fix screen session regex
|
||||
* usr/lib/byobu/updates_available:
|
||||
- Add support for opkg (OpenWrt)
|
||||
* usr/lib/byobu/users:
|
||||
- Handle stderr for ps, e.g. unsupported options
|
||||
- Fix trailing '#' sign
|
||||
* usr/lib/byobu/whoami:
|
||||
- Use id if the whoami command is not available
|
||||
- Read from /etc/passwd if the getent command is not available
|
||||
|
@ -22,7 +22,7 @@
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
__users_detail() {
|
||||
ps -ef | grep "sshd:.*@" | grep -v grep
|
||||
ps -ef 2>/dev/null | grep "sshd:.*@" | grep -v grep
|
||||
}
|
||||
|
||||
__users() {
|
||||
@ -35,7 +35,7 @@ __users() {
|
||||
count=$(pgrep -f "^sshd:.*@|^/usr/sbin/sshd -i" | wc -l) || return
|
||||
fi
|
||||
if [ $count -gt 0 ]; then
|
||||
color b w r; printf "%d" "$count"; color -; color w r; printf "#"; color --
|
||||
color b w r; printf "%d" "$count"; color -; color w r; printf "##"; color --
|
||||
else
|
||||
rm -f "$BYOBU_RUN_DIR/status.$BYOBU_BACKEND/users"*
|
||||
fi
|
||||
|
Loading…
x
Reference in New Issue
Block a user