Author Topic: Macro to run clang-format on file in the editor?  (Read 262 times)

rowbearto

  • Senior Community Member
  • Posts: 1617
  • Hero Points: 118
Macro to run clang-format on file in the editor?
« on: December 18, 2019, 04:42:59 pm »
I remember someone posted this some time back, but I can't find it.

I'd like to have a macro so that I can have my source file in the editor, run the command, and it will get clang-format run on it, and then the editor would be updated with the output of clang-format.

How to do this?

Clark

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 5153
  • Hero Points: 425
Re: Macro to run clang-format on file in the editor?
« Reply #1 on: December 18, 2019, 04:49:57 pm »
The filter_command command looks promising.

rowbearto

  • Senior Community Member
  • Posts: 1617
  • Hero Points: 118
Re: Macro to run clang-format on file in the editor?
« Reply #2 on: December 18, 2019, 04:50:36 pm »
Thanks Clark. I found the post I was talking about, it does use filter_command:

https://community.slickedit.com/index.php/topic,15729.msg60061.html#msg60061