Is there a text editor that will “pretty print” for display without changing the underlying text?

感情迁移 提交于 2020-01-03 02:55:29

问题


There are two competing requirements

1) I want to pretty print so that I can read and understand code written by my peers

2) I don't want to check in the pretty printed code to source control because...

  • It might not meet the coding standard where I work
  • When reviewing history in source control, formatting changes obscure the 'real' changes.

For discussion of problems checking in formatting changes, see this other stackoverflow question

  • Committing when changing source formatting?

At the same time, I still need to be able to edit the file and save changes. I want to be able to edit the ugly text while I see the pretty text.

Does anyone know an editor with a feature like this?

来源:https://stackoverflow.com/questions/7372847/is-there-a-text-editor-that-will-pretty-print-for-display-without-changing-the

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!