Ask Your Question

Reformatting all files in a project

asked 2020-06-14 06:45:08 -0600

Michael's avatar

updated 2020-06-15 14:39:10 -0600

Could this be provided as a convenience function? I'm using black, and sometimes I receive projects with horrible formatting. Because Wing knows which sources belong to the project, an internal solution is often preferable compared to some script, rewriting anything in his scope. At this moment I'm not sure if the Wing API provides the relevant information, but the particular function has IMO enough value to justify a standard interface in the main application.

This should certainly only be available as mostly one-time deliberate manual step for initial formatting, though. Perhaps with some confirmation dialog or a non-standard command to be explicitly bound.

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted

answered 2020-06-15 09:28:57 -0600

This is something we'll consider adding in the future. In the meantime, you could use the GetAllFiles method of the CAPIProject object to get all the project files and then use black on them.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools



Asked: 2020-06-14 06:45:08 -0600

Seen: 482 times

Last updated: Jun 15 '20