--- a/ProjectDjango/Project.py Sun Dec 31 16:59:10 2017 +0100 +++ b/ProjectDjango/Project.py Thu Jan 25 10:41:24 2018 +0100 @@ -1729,6 +1729,20 @@ # remove the project directory if it exists already ppath = os.path.join(path, projectName) if os.path.exists(ppath): + okToRemove = E5MessageBox.yesNo( + self.__ui, + title, + self.tr("""<p>The Django project path <b>{0}</b> exists""" + """ already. Shall it be removed and recreated?""" + """</p>""").format(ppath)) + if not okToRemove: + E5MessageBox.information( + self.__ui, + title, + self.tr("""<p>Please add the files to the eric project""" + """ manually.</p>""")) + return True + shutil.rmtree(ppath, ignore_errors=True) args = [] @@ -1745,7 +1759,7 @@ title, self.tr("""<p>The <b>django-admin.py</b> script is""" """ not in the path. Aborting...</p>""")) - return + return False args.append("startproject") args.append(projectName)