Fix some lint warnings (#189)
Remove unused imports or variable, and apply suggestions from https://adamj.eu/tech/2019/09/12/how-i-import-pythons-datetime-module/.
This commit is contained in:
committed by
GitHub
parent
f59390815c
commit
1022d8f816
@@ -1,6 +1,6 @@
|
||||
from hashlib import sha1
|
||||
from pathlib import Path
|
||||
from subprocess import run, PIPE
|
||||
from subprocess import run
|
||||
|
||||
|
||||
class Git:
|
||||
@@ -18,7 +18,7 @@ class Git:
|
||||
child = run(f"git {cmd}", capture_output=True, timeout=300, check=True, shell=True, cwd=self.repo_dir)
|
||||
return child.stdout.decode("utf-8").strip().split("\n")
|
||||
except ChildProcessError as ex:
|
||||
raise RuntimeError(f"Failed to run '{git_command}': {ex}")
|
||||
raise RuntimeError(f"Failed to run '{cmd}': {ex}")
|
||||
|
||||
def setup(self, bare: bool = False):
|
||||
"""Creates the repository path and runs:
|
||||
|
||||
Reference in New Issue
Block a user