Skip to content

Commit

Permalink
refactor(git): remove suppression of stdout and stderr in git commands (
Browse files Browse the repository at this point in the history
  • Loading branch information
sasa-tomic authored Nov 21, 2024
1 parent 51eac44 commit af41ee5
Showing 1 changed file with 0 additions and 10 deletions.
10 changes: 0 additions & 10 deletions release-controller/git_repo.py
Original file line number Diff line number Diff line change
Expand Up @@ -285,14 +285,10 @@ def checkout(self, ref: str):
subprocess.check_call(
["git", "reset", "--hard"],
cwd=self.dir,
stdout=subprocess.DEVNULL,
stderr=subprocess.DEVNULL,
)
subprocess.check_call(
["git", "checkout", ref],
cwd=self.dir,
stdout=subprocess.DEVNULL,
stderr=subprocess.DEVNULL,
)
if (
subprocess.check_output(
Expand All @@ -305,8 +301,6 @@ def checkout(self, ref: str):
subprocess.check_call(
["git", "reset", "--hard", f"origin/{ref}"],
cwd=self.dir,
stdout=subprocess.DEVNULL,
stderr=subprocess.DEVNULL,
)

def parent(self, object: str) -> str:
Expand Down Expand Up @@ -335,16 +329,12 @@ def _fetch_notes(self):
subprocess.check_call(
["git", "fetch", "origin", f"{ref}:{ref}", "-f", "--prune"],
cwd=self.dir,
stdout=subprocess.DEVNULL,
stderr=subprocess.DEVNULL,
)

def _push_notes(self, namespace: str):
subprocess.check_call(
["git", "push", "origin", f"refs/notes/{namespace}", "-f"],
cwd=self.dir,
stdout=subprocess.DEVNULL,
stderr=subprocess.DEVNULL,
)

def _notes(self, namespace: str, *args) -> str:
Expand Down

0 comments on commit af41ee5

Please sign in to comment.