Thanks for the excellent replies!

  Further argument goes without saying I'd think, it's not only more efficient 
and code friendly to make use of the python standard path library as well as 
readability within the code is greatly enhanced when using os.path for path 
splicing and 'string'.join() for other joining things and while there are no 
personal griefs going on regarding the shutil module the process of copying a 
single file into a directory should be rather straightforward and effortless.
  However, I've updated my code accordingly and was about to try out shutil vs 
ctypes.windll.kernel32 when I noticed my destination path wasn't getting picked 
up...

  Explanation coming in this simplified example:
[code]
import os
import maya.cmds

workspace = maya.cmds.workspace( q=1,rd=1 )
directory = maya.cmds.workspace( 'scenes' , q=1 , fre=1 )
scenepath = os.path.join( workspace , 'my folder')

print scenepath
print os.path.join( scenepath , 'my uNkle Bobo' )
print '/'.join( [ scenepath , 'tends to join things' ] )

[output]
C:/Users/aevar_000/Dropbox/Samansafn/Verkefni/Cube/my folder
C:/Users/aevar_000/Dropbox/Samansafn/Verkefni/Cube/my folder\my uNkle Bobo
C:/Users/aevar_000/Dropbox/Samansafn/Verkefni/Cube/my folder/tends to join 
things

[resolution]
  My uNkle Bobo is broken, path constructed him using two different slash 
schemes.  The / symbols are what Maya is returning and \ is coming from path.

  Any ideas?  The platform module comes to mind but I've never used it that 
much so any info will be great, or perhaps I should just create a custom 
filerule and query that one with fre='custom' ?

-- 
You received this message because you are subscribed to the Google Groups 
"Python Programming for Autodesk Maya" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to