Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save AndrewtConroy/540c77fb638fd37ea3d14912ce489901 to your computer and use it in GitHub Desktop.
Save AndrewtConroy/540c77fb638fd37ea3d14912ce489901 to your computer and use it in GitHub Desktop.
Selects joints with 'jnt' prefix - python
import maya.cmds as cmds
pfx ='jnt'
jointList = []
fullList = cmds.ls(type='joint')
for item in fullList:
if item.startswith(pfx ):
jointList.append(item)
cmds.select(jointList)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment