List Info

Thread: Suggestion for splice.py (venus codebase)




Suggestion for splice.py (venus codebase)
user name
2007-04-02 16:06:43
Hi,

   I store some of my theme config files in RCS which makes them read only. If any files on bill_of_material changes, splice.py tries to copy them to the destination, but they are read only and it fails. I just added a small patch to splice.py which will make the destination writable if it exists so that copy of file is successful. Let me know if it can be added to your repository Sam.

Thanks!
Amit

--- venus/planet/splice.py.orig 2007-03-31 14:19: 04.000000000 -0700
+++ venus/planet/splice.py      2007-04-02 14:02:17.000000000 -0700
-130,6 +130,8
         ;    dest_dir = os.path.split(dest)[0]
         ;    if not os.path.exists(dest_dir): os.makedirs (dest_dir)

     ;        log.info("Copying %s to %s", source, dest)
+        ;    if(os.path.exists(dest)):
;           ;   os.chmod(dest, 0644)
          ;   shutil.copyfile(source, dest)
          ;   shutil.copystat(source, dest)

Re: Suggestion for splice.py (venus codebase)
country flaguser name
United States
2007-04-09 07:50:33
Amit Chakradeo (अमित चक्रदेव) wrote:
> Hi,
> 
>    I store some of my theme config files in RCS which
makes them read 
> only. If any files on bill_of_material changes,
splice.py tries to copy 
> them to the destination, but they are read only and it
fails. I just 
> added a small patch to splice.py which will make the
destination 
> writable if it exists so that copy of file is
successful. Let me know if 
> it can be added to your repository Sam.

Committed... thanks!

- Sam Ruby
-- 
devel mailing list
devellists.planetplanet.org

http://lists.planetplanet.org/mailman/listinfo/devel

[1-2]

about | contact  Other archives ( Real Estate discussion Medical topics )