From 824dc8dcdde6ad80684685e41b477ed48087b845 Mon Sep 17 00:00:00 2001 From: Pratik Date: Fri, 13 Jun 2025 12:51:04 +0000 Subject: [PATCH] fix: git command error --- crm/www/crm.py | 20 ------------------- frontend/src/components/Modals/AboutModal.vue | 18 ----------------- 2 files changed, 38 deletions(-) diff --git a/crm/www/crm.py b/crm/www/crm.py index 94f8142a..070372dd 100644 --- a/crm/www/crm.py +++ b/crm/www/crm.py @@ -45,7 +45,6 @@ def get_boot(): "user": frappe.db.get_value("User", frappe.session.user, "time_zone") or get_system_timezone(), }, - "app_version": get_app_version(), } ) @@ -54,25 +53,6 @@ def get_default_route(): return "/crm" -def get_app_version(): - app = "crm" - branch = run_git_command(f"cd ../apps/{app} && git rev-parse --abbrev-ref HEAD") - commit = run_git_command(f"git -C ../apps/{app} rev-parse --short=7 HEAD") - tag = run_git_command(f"git -C ../apps/{app} describe --tags --abbrev=0") - dirty = run_git_command(f"git -C ../apps/{app} diff --quiet || echo 'dirty'") == "dirty" - commit_date = run_git_command(f"git -C ../apps/{app} log -1 --format=%cd") - commit_message = run_git_command(f"git -C ../apps/{app} log -1 --pretty=%B") - - return { - "branch": branch, - "commit": commit, - "commit_date": commit_date, - "commit_message": commit_message, - "tag": tag, - "dirty": dirty, - } - - def run_git_command(command): try: with open(os.devnull, "wb") as null_stream: diff --git a/frontend/src/components/Modals/AboutModal.vue b/frontend/src/components/Modals/AboutModal.vue index b118d3f4..a6addea0 100644 --- a/frontend/src/components/Modals/AboutModal.vue +++ b/frontend/src/components/Modals/AboutModal.vue @@ -6,22 +6,6 @@

Frappe CRM

-
-
- {{ appVersion.branch != 'main' ? appVersion.branch : '' }} - - -
- - - - -

@@ -95,6 +79,4 @@ let links = [ icon: LucideHeadset, }, ] - -let appVersion = window.app_version