Skip to content

Commit 165ae68

Browse files
chore: clean-up unused repo operator methods (#409)
1 parent 8c73d08 commit 165ae68

File tree

2 files changed

+0
-11
lines changed

2 files changed

+0
-11
lines changed

.github/workflows/auto-release.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ on:
66

77
jobs:
88
semantic-version:
9-
if: false # TODO(CG-10755): merge this with release.yml
109
name: Semantic version
1110
runs-on: ubuntu-latest
1211
outputs:

src/codegen/git/repo_operator/repo_operator.py

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -346,10 +346,6 @@ def checkout_branch(self, branch_name: str | None, *, remote: bool = False, remo
346346
logger.exception(f"Error with Git operations: {e}")
347347
raise
348348

349-
def get_diff_files_from_ref(self, ref: str):
350-
diff_from_ref_files = self.git_cli.git.diff(ref, name_only=True).split("\n")
351-
return diff_from_ref_files
352-
353349
def get_diffs(self, ref: str | GitCommit, reverse: bool = True) -> list[Diff]:
354350
"""Gets all staged diffs"""
355351
self.git_cli.git.add(A=True)
@@ -377,12 +373,6 @@ def commit_changes(self, message: str, verify: bool = False) -> bool:
377373
logger.info("No changes to commit. Do nothing.")
378374
return False
379375

380-
def stage_and_commit_file(self, message: str, filepath: str) -> None:
381-
"""Stage all changes and commit them with the given message."""
382-
logger.info(f"Staging and committing changes to {filepath}...")
383-
self.git_cli.git.add(filepath)
384-
self.git_cli.git.commit("-m", message)
385-
386376
@abstractmethod
387377
def push_changes(self, remote: Remote | None = None, refspec: str | None = None, force: bool = False) -> PushInfoList:
388378
"""Push the changes to the given refspec of the remote repository.

0 commit comments

Comments
 (0)