I'm using Tramp to edit files on a remote machine, and when I run clang-format-buffer, it doesn't actually format the buffer. I get a message (clang-format: success) in the minibuffer, but the expected changes are not made in the buffer. If I use clang-format-buffer on a local copy of the file, it formats the file correctly.

What am I missing to get it to operate correctly on the buffer in Emacs using Tramp?

1 Answer 1


I don't know which package you are using, but I guess it is clang-format-20191121.1708 from MELPA. I've inspected the source code, and it uses call-process-region internally. call-process is agnostic to remote files, I suggest you contact the author of that package for supporting of remote files.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.