Open tgroshon opened 6 years ago
I got around this issue by just running isort
on save of every python file.
(defun my-isort ()
"When in Python Mode, call isort on save"
(when (eq major-mode 'python-mode)
(shell-command-to-string (format "isort %s" buffer-file-name))))
;; Run on file save
(add-hook 'after-save-hook 'my-isort)
When using py-isort on Emacs 25.3 Windows 10 Pro, it fails with the following message:
Searching for program: No such file or directory, diff
Installing
isort
and calling it from powershell works.The failure seems to be when calling
diff
to see if the file was isorted or not: https://github.com/paetzke/py-isort.el/blob/master/py-isort.el#L153Is there a way to do the same operation without using
diff
?