Selaa lähdekoodia

[docs] delete user folder before writing new files (so old files will be deleted)

version-14
Rushabh Mehta 9 vuotta sitten
vanhempi
commit
c47590ae04
1 muutettua tiedostoa jossa 4 lisäystä ja 2 poistoa
  1. +4
    -2
      frappe/utils/setup_docs.py

+ 4
- 2
frappe/utils/setup_docs.py Näytä tiedosto

@@ -116,8 +116,10 @@ class setup_docs(object):


# make /user # make /user
user_path = os.path.join(self.docs_path, "user") user_path = os.path.join(self.docs_path, "user")
if not os.path.exists(user_path):
os.makedirs(user_path)
if os.path.exists(user_path):
shutil.rmtree(user_path, ignore_errors=True)

os.makedirs(user_path)


# make /assets/img # make /assets/img
img_path = os.path.join(self.docs_path, "assets", "img") img_path = os.path.join(self.docs_path, "assets", "img")


Ladataan…
Peruuta
Tallenna