Skip to content

Commit

Permalink
[pre-commit.ci] pre-commit autoupdate (#367)
Browse files Browse the repository at this point in the history
* [pre-commit.ci] pre-commit autoupdate

updates:
- [github.com/astral-sh/ruff-pre-commit: v0.4.8 → v0.5.0](astral-sh/ruff-pre-commit@v0.4.8...v0.5.0)

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* revert noqa changed

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Ivan Shcheklein <[email protected]>
  • Loading branch information
pre-commit-ci[bot] and shcheklein authored Jul 1, 2024
1 parent 17f56cf commit cbcbed0
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 11 deletions.
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ repos:
- id: sort-simple-yaml
- id: trailing-whitespace
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: 'v0.4.8'
rev: 'v0.5.0'
hooks:
- id: ruff
args: [--fix, --exit-non-zero-on-fix]
Expand Down
20 changes: 10 additions & 10 deletions src/scmrepo/git/credentials.py
Original file line number Diff line number Diff line change
Expand Up @@ -136,8 +136,8 @@ def _prepare_command(self, action: Optional[str] = None) -> Union[str, list[str]
if not shutil.which(executable) and shutil.which("git"):
# If the helper cannot be found in PATH, it might be
# a C git helper in GIT_EXEC_PATH
git_exec_path = subprocess.check_output(
("git", "--exec-path"), # noqa: S603
git_exec_path = subprocess.check_output( # noqa: S603
("git", "--exec-path"),
text=True,
).strip()
if shutil.which(executable, path=git_exec_path):
Expand All @@ -158,8 +158,8 @@ def get(self, credential: "Credential", **kwargs) -> "Credential":
helper_input.append("")

try:
res = subprocess.run(
cmd, # noqa: S603
res = subprocess.run( # noqa: S603
cmd,
check=True,
capture_output=True,
input="\n".join(helper_input),
Expand Down Expand Up @@ -199,8 +199,8 @@ def store(self, credential: "Credential", **kwargs):
helper_input.append("")

try:
res = subprocess.run(
cmd, # noqa: S603
res = subprocess.run( # noqa: S603
cmd,
capture_output=True,
input="\n".join(helper_input),
encoding=self._encoding,
Expand All @@ -224,8 +224,8 @@ def erase(self, credential: "Credential", **kwargs):
helper_input.append("")

try:
res = subprocess.run(
cmd, # noqa: S603
res = subprocess.run( # noqa: S603
cmd,
capture_output=True,
input="\n".join(helper_input),
encoding=self._encoding,
Expand Down Expand Up @@ -448,8 +448,8 @@ def __init__(self, command: str):
def input(self, prompt: str) -> str:
argv = [self.command, prompt]
try:
res = subprocess.run(
argv, # noqa: S603
res = subprocess.run( # noqa: S603
argv,
check=True,
capture_output=True,
encoding=locale.getpreferredencoding(),
Expand Down

0 comments on commit cbcbed0

Please sign in to comment.