In Intellij, how do I toggle between camel case and underscore spaced?

后端 未结 5 687
时光取名叫无心
时光取名叫无心 2021-01-29 20:08

At my company we have two different style guides for java vs sql. In java I have a field named historyOfPresentIllness and when i write the sql, I want to name it

5条回答
  •  粉色の甜心
    2021-01-29 20:33

    From snake_case to CamelCase

    • Find: (\w)[_]{1,1}([a-z])
    • Replace: $1\U$2
    • Settings:
      • Match Case
      • Regex

    From CamelCase to snake_case:

    • Find: ([A-Z])
    • Replace: \_\L$1
    • Settings:
      • Match Case
      • Regex

提交回复
热议问题