Lines Matching defs:commit
7 commit to find the latest english commit from the translation commit
24 commit 42fb9cfd5b18 ("Documentation: dev-tools: Add link to RV docs")
45 def get_latest_commit_from(file_path, commit):
46 """Get the latest commit from the specified commit for the specified file"""
47 command = f"git log --pretty=format:%H%n%aD%n%cD%n%n%B {commit} -1 -- {file_path}"
66 """Get the latest origin commit from the translation commit"""
71 logging.debug("tracked origin commit id: %s", o_from_t["hash"])
76 """Get the latest origin commit from the formatted translation commit:
77 (1) update to commit HASH (TITLE)
78 (2) Update the translation through commit HASH (TITLE)
80 # catch flag for 12-bit commit hash
82 # pattern 1: contains "update to commit HASH"
83 pat_update_to = re.compile(rf'update to commit {hash_re}')
84 # pattern 2: contains "Update the translation through commit HASH"
85 pat_update_translation = re.compile(rf'Update the translation through commit {hash_re}')
103 logging.debug("tracked origin commit id: %s", o_from_t["hash"])
118 def pretty_output(commit):
119 """Pretty print the commit message"""
120 command = f"git log --pretty='format:%h (\"%s\")' -1 {commit}"
126 def valid_commit(commit):
127 """Check if the commit is valid or not"""
128 msg = pretty_output(commit)
143 logging.error("Cannot find the latest commit for %s", file_path)
152 logging.error("Error: Cannot find the latest origin commit for %s", file_path)
163 for commit in commits:
164 if valid_commit(commit):
165 logging.info("commit %s", pretty_output(commit))