mirror of
https://github.com/frappe/bench.git
synced 2025-01-08 00:04:38 +00:00
fix: Archive app for different repo/app names
This commit is contained in:
parent
3e448d4d42
commit
3af6058d1b
@ -198,7 +198,7 @@ class App(AppMeta):
|
||||
|
||||
@step(title="Archiving App {repo}", success="App {repo} Archived")
|
||||
def remove(self, no_backup: bool = False):
|
||||
active_app_path = os.path.join("apps", self.repo)
|
||||
active_app_path = os.path.join("apps", self.app_name)
|
||||
|
||||
if no_backup:
|
||||
if not os.path.islink(active_app_path):
|
||||
@ -209,7 +209,7 @@ class App(AppMeta):
|
||||
else:
|
||||
archived_path = os.path.join("archived", "apps")
|
||||
archived_name = get_available_folder_name(
|
||||
f"{self.repo}-{date.today()}", archived_path
|
||||
f"{self.app_name}-{date.today()}", archived_path
|
||||
)
|
||||
archived_app_path = os.path.join(archived_path, archived_name)
|
||||
|
||||
|
@ -131,6 +131,9 @@ class Bench(Base, Validator):
|
||||
except InvalidRemoteException:
|
||||
if not force:
|
||||
raise
|
||||
except ValueError:
|
||||
pass
|
||||
|
||||
self.apps.sync()
|
||||
# self.build() - removed because it seems unnecessary
|
||||
self.reload(_raise=False)
|
||||
|
Loading…
Reference in New Issue
Block a user