PluginManager/PluginManager.py

changeset 45
9a18f4dbb493
parent 15
f6ccc31d6e72
child 110
c9a969db1469
equal deleted inserted replaced
44:fe5cd20cb0eb 45:9a18f4dbb493
162 if not os.path.exists(self.pluginDirs["global"]) and \ 162 if not os.path.exists(self.pluginDirs["global"]) and \
163 os.access(Utilities.getPythonModulesDirectory(), os.W_OK): 163 os.access(Utilities.getPythonModulesDirectory(), os.W_OK):
164 # create the global plugins directory 164 # create the global plugins directory
165 os.mkdir(self.pluginDirs["global"], 0o755) 165 os.mkdir(self.pluginDirs["global"], 0o755)
166 fname = os.path.join(self.pluginDirs["global"], "__init__.py") 166 fname = os.path.join(self.pluginDirs["global"], "__init__.py")
167 f = open() 167 f = open(fname, "w", encoding = "utf-8")
168 f.write('# -*- coding: utf-8 -*-' + os.linesep) 168 f.write('# -*- coding: utf-8 -*-' + os.linesep)
169 f.write(os.linesep) 169 f.write(os.linesep)
170 f.write('"""' + os.linesep) 170 f.write('"""' + os.linesep)
171 f.write('Package containing the global plugins.' + os.linesep) 171 f.write('Package containing the global plugins.' + os.linesep)
172 f.write('"""' + os.linesep) 172 f.write('"""' + os.linesep)

eric ide

mercurial