tools: Fix isort
- Isort's has patches containing absolute paths that don't apply. - Let isort apply the patch itself. - The patch_command can either do the patch or return a patch.
This commit is contained in:
parent
ac7c7010df
commit
a8f3261ab8
2 changed files with 2 additions and 2 deletions
|
|
@ -794,7 +794,7 @@ class Screen:
|
|||
path_colored = lscolors.path_colored(path)
|
||||
self._log.log_message([in_green("Patching file: "), path_colored])
|
||||
subprocess.run(f"{result.tool.patch_command} {path} | patch -p0", shell=True,
|
||||
stdout=subprocess.PIPE, stderr=subprocess.PIPE)
|
||||
capture_output=True)
|
||||
subprocess.run(["touch", path])
|
||||
|
||||
def toggle_status_style(self):
|
||||
|
|
|
|||
|
|
@ -103,7 +103,7 @@ tools_for_extensions = [
|
|||
dependencies = ["python3-isort", "python3-colorama"]
|
||||
url = "https://pycqa.github.io/isort/"
|
||||
command = "/usr/bin/python3 -m isort --check-only --diff --color"
|
||||
patch_command = "/usr/bin/python3 -m isort --diff"
|
||||
patch_command = "/usr/bin/python3 -m isort --overwrite-in-place"
|
||||
has_color = true
|
||||
|
||||
[perl_syntax]
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue