You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

9 lines
272 B

#/bin/sh
groups=$(getent group)
for i in $groups;
do
group_name=$(echo $i | cut -d ":" -f 1);
users=$(groups $group_name | cut -d ":" -f 2 | tr ' ' ',' | cut -c 2-);
date=$(date +%s)
echo "time=$date group_name=$group_name users=\"$users\"";
done