The help document is of no help on this subject matter, in fact the help file lists three separate locations which make no sense to me since I've never used a Mac.
I believe you will find these located under: Library/Preferences/Autodesk/maya/2018/scripts where 2018 can be replaced by whatever version you have installed. I'm not 100% sure on this, but I "think" it's correct.
I cannot say with confidence, as the only reason I even know where the version specific scripts folder is located is because I have deployed scripts to OSX customers. I'm punting here, but my guess would be: Library/Preferences/Autodesk/maya/scripts
as that would mirror the PC location of: username/Documents/maya/scripts
I'm honestly surprised some Mac users haven't chimed in on this one
If you really need your scripts to be accessible by all installed versions of Maya, you could always set them up as a module.
This is what I eventually did to avoid the whole mess of dealing with various different maya version installations. It's pretty easy and honestly makes maintaining your code a lot easier to manage.
Yeah I've got a lot of complaints that for Mac users when they purchase my scripts they don't know where to put them so the script fails to load. To avoid this problem altogether I'm going to skip external script files and just embed all the code in a shelf button that way no matter who buys it the install will be exactly the same.
Keep in mind that the Library folder is by default hidden from user. You have to either access the path directly in Finder from the menu or make the folder permanently visible (view options in user home directory if memory serves).
Replies
Library/Preferences/Autodesk/maya/2018/scripts
where 2018 can be replaced by whatever version you have installed.
I'm not 100% sure on this, but I "think" it's correct.
Library/Preferences/Autodesk/maya/scripts
as that would mirror the PC location of:
username/Documents/maya/scripts
I'm honestly surprised some Mac users haven't chimed in on this one
If you really need your scripts to be accessible by all installed versions of Maya, you could always set them up as a module.
This is what I eventually did to avoid the whole mess of dealing with various different maya version installations. It's pretty easy and honestly makes maintaining your code a lot easier to manage.
https://help.autodesk.com/view/MAYAUL/2017/ENU/?guid=__files_GUID_130A3F57_2A5D_4E56_B066_6B86F68EEA22_htm