fix for running datatoc on files in a subdir (was adding slashes into the C variable...
authorCampbell Barton <ideasman42@gmail.com>
Mon, 9 Nov 2009 20:03:59 +0000 (20:03 +0000)
committerCampbell Barton <ideasman42@gmail.com>
Mon, 9 Nov 2009 20:03:59 +0000 (20:03 +0000)
release/datafiles/datatoc.py

index 70bb348ad02efe4c61a1216593a1e3f5fabecbd5..a78b64c5095a3cc92fbfa13ecea7a4946a1ce04d 100755 (executable)
@@ -48,6 +48,7 @@ if filename[0] == ".":
 cname = filename + ".c"
 sys.stdout.write("Making C file <%s>\n" % cname)
 
+filename = filename.split("/")[-1].split("\\")[-1]
 filename = filename.replace(".", "_")
 sys.stdout.write(str(size))
 sys.stdout.write("\n")