~azzar1/unity/add-show-desktop-key

« back to all changes in this revision

Viewing changes to setup.py

  • Committer: mattgiuca
  • Date: 2008-01-29 00:25:38 UTC
  • Revision ID: svn-v3-trunk0:2b9c9e99-6f39-0410-b283-7f802c844ae2:trunk:318
setup.py: action_copyfile now handles errors as warnings, instead of quitting
the whole process.

Show diffs side-by-side

added added

removed removed

Lines of Context:
817
817
def action_copyfile(src, dst, dry):
818
818
    """Copies one file to a new location. Creates all parent directories
819
819
    as necessary.
 
820
    Warn if file not found.
820
821
    """
821
822
    dstdir = os.path.split(dst)[0]
822
823
    if not os.path.isdir(dstdir):
826
827
        try:
827
828
            shutil.copyfile(src, dst)
828
829
            shutil.copymode(src, dst)
829
 
        except shutil.Error:
830
 
            pass
 
830
        except (shutil.Error, IOError), e:
 
831
            print "Warning: " + str(e)
831
832
 
832
833
def action_symlink(src, dst, dry):
833
834
    """Creates a symlink in a given location. Creates all parent directories