Hi,
I am looking for assistance in running something in Scriptrunner (as I don't have direct DB access) to identify all users who are not in any groups.
I found this, however it doesn't appear to work with my Jira v7.8.
Thanks in advance!
To accomplish, please perform the following:
Navigate to "Administraton">"Add Ons">"Script Console"
import com.atlassian.jira.component.ComponentAccessor
import com.atlassian.jira.user.util.UserUtil
UserUtil userUtil = ComponentAccessor.getUserUtil()
result = ''
userUtil.getUsers().findAll{userUtil.getGroupsForUser(it.getName()).size() == 0}.each{ u ->
result += u.name + "\r\n"
}
result
From the link that you provided, I was able to get this running and working. It gave me all usernames that do not have a group attached.
It did throw a couple of warning about deprecated classes, but it seemed to work.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.