diff --git a/src/metadata_review_lib.py b/src/metadata_review_lib.py index d959cb9..d59e935 100644 --- a/src/metadata_review_lib.py +++ b/src/metadata_review_lib.py @@ -6,22 +6,17 @@ import subprocess import h5py import yaml -import shutil import src.g5505_utils as utils import src.hdf5_vis as hdf5_vis #import input_files.config_file as config_file -import src.hidden as hidden import numpy as np -import pygit2 as pygit - YAML_EXT = ".yaml" TXT_EXT = ".txt" -repo_obj = pygit.Repository(os.path.abspath(os.curdir)) def get_review_status(filename_path): @@ -35,22 +30,6 @@ def get_review_status(filename_path): workflow_steps.append(line) return workflow_steps[-1] -def checkout_review_branch(branch_name): - # Create a new branch - #branch_name = 'metadata-review-by-'+initials - head_commit = repo_obj.head.peel()# Get the commit hash associated with HEAD - - checkout_branch_command = lambda branch_name : ['git','checkout', branch_name] - output = subprocess.run(checkout_branch_command(branch_name), capture_output=True,text=True,check=True) - - print(output.stdout) - - #if not branch_name in repo_obj.branches: - # branch = repo_obj.create_branch(branch_name, head_commit) - #else: - # branch = repo_obj.branches[branch_name] - #repo_obj.checkout(branch) - current_branch_command = ['git','branch','--show-current'] status_command = ['git','status'] add_command = lambda add_list: ['git','add'] + add_list