-
Notifications
You must be signed in to change notification settings - Fork 347
Stylish haskell after save #1268
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
(call-process cmd filename | ||
(list (current-buffer) err-file) nil))) | ||
(_errcode | ||
(call-process-region (point-min) (point-max) cmd nil (list (buffer-name tmp-buf) (buffer-name err-buf)) nil)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
AFAIK can't have buffer for STDERR, has to be a file.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This worked as expected. I tested it. I could do a few more tests or something to be absolutely certain.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Interesting. It should be more like:
(call-process-region (point-min) (point-max) cmd nil
(list tmp-buf (make-temp-name "tempxx")) nil))
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
And again, temp file has to be deleted using unwind-protect
.
Can you rebase on top of current master? |
wasamasa on freenode #emacs helped me out a bit: https://gist.github.com/wasamasa/b89a54f56f3ef86d20cd6b8d85e2a5d8/961428e28279cb38955640211c6cbe3b3cc0fa6b |
Need to use |
@wraithm: This is a lovely contribution, I would love to get this in. Can you rebease on mater and add |
Okay! This actually works. It handles errors appropriately.