Kiln » TortoiseHg » TortoiseHg
Clone URL:  
Pushed to one repository · View In Graph Contained in 0.8, 0.8.1, and 0.8.2

setup: do not overwrite existing __paths__.py file

Changeset bbeda1f7e5bb

Parent d45a11d7fcef

by Steve Borho

Changes to one file · Browse files at bbeda1f7e5bb Showing diff from parent d45a11d7fcef Diff from another changeset...

Change 1 of 1 Show Entire File setup.py Stacked
 
124
125
126
127
128
129
130
131
132
 
 
 
 
 
 
 
 
133
134
135
 
124
125
126
 
 
 
 
 
 
127
128
129
130
131
132
133
134
135
136
137
@@ -124,12 +124,14 @@
  ['contrib/nautilus-thg.py'])]     # Create a __paths__.py. Distributions will need to supply their own - f = open('thgutil/__paths__.py', "w") - f.write('bin_path = "/usr/bin"\n') - f.write('license_path = "/usr/share/doc/tortoisehg/Copying.txt.gz"\n') - f.write('locale_path = "/usr/share/locale"\n') - f.write('icon_path = "/usr/share/pixmaps/tortoisehg/icons"\n') - f.close() + paths_file = os.path.join('thgutil', '__paths__.py') + if not os.path.exists(paths_file): + f = open(paths_file, "w") + f.write('bin_path = "/usr/bin"\n') + f.write('license_path = "/usr/share/doc/tortoisehg/Copying.txt.gz"\n') + f.write('locale_path = "/usr/share/locale"\n') + f.write('icon_path = "/usr/share/pixmaps/tortoisehg/icons"\n') + f.close()     return _scripts, _packages, _data_files, _extra