Skip to content

Commit

Permalink
fix git status check
Browse files Browse the repository at this point in the history
  • Loading branch information
Tom-Willemsen committed Aug 28, 2024
1 parent 25d0d6d commit 629802f
Showing 1 changed file with 3 additions and 11 deletions.
14 changes: 3 additions & 11 deletions installation_and_upgrade/ibex_install_utils/tasks/git_tasks.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@

class GitTasks(BaseTasks):
@task(f"Show Git status in {EPICS_PATH}")
def show_git_status(self):
subprocess.call(f"cd {EPICS_PATH} && git status", shell=True)
def show_git_status(self) -> None:
subprocess.call(f"cd /d {EPICS_PATH} && git status", shell=True)

@task("Swap instrument git branch to release on CONTROL-SVCS")
def checkout_to_release_branch(self):
def checkout_to_release_branch(self) -> None:
version_pattern = r"^\d+\.\d+\.\d+$"
if self._server_source_dir.endswith("32"):
remote_repo = "EPICS32.git"
Expand Down Expand Up @@ -61,11 +61,3 @@ def checkout_to_release_branch(self):
except subprocess.CalledProcessError as e:
print(f"Error checking out to new release branch and push: {e}")
print("Branch may previously exist either locally or remotely - intervention required")


# something for the future in case creting new beranch fails - maybe one exists we want to use?
# try:
# subprocess.check_call(f"cd {EPICS_PATH} && git checkout %COMPUTERNAME%", shell=True)
# print("Switched to existing release branch")
# except subprocess.CalledProcessError as e:
# print(f"Error switching to existing release branch and push: {e}")

0 comments on commit 629802f

Please sign in to comment.