Skip to content

Instantly share code, notes, and snippets.

@RedForty
Last active December 24, 2018 07:23
Show Gist options
  • Save RedForty/e705016d2bf6f24171d6f2006cccc2fa to your computer and use it in GitHub Desktop.
Save RedForty/e705016d2bf6f24171d6f2006cccc2fa to your computer and use it in GitHub Desktop.
Adds an icon path to your environment variable for relative icon path access in Maya
# ---------------------------------------------------------------------------- #
# Custom Icon Paths
import os
icon_paths = [ # Mind the lack of comma after the last item in the list!
'F:/Dropbox/Code/Maya/KlugTools/Icons',
'F:/Dropbox/Code/Maya/ForeignTools/Icons' # No comma!
]
os.environ['XBMLANGPATH'] += os.pathsep + (os.pathsep).join(icon_paths)
# ---------------------------------------------------------------------------- #
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment