I am looking for solution for importing Eclipse Java Formatter Profile in Visual Studio Code. In order to go with coding complaince. For example in IntelliJ and Eclipse for Java we do this way:
IntelliJ
- Download the config (attached)
- In the Intellij settings (Ctrl+Alt+S), go to Code Style
- Next to Scheme, click Manage and then Import...
- Select 'Eclipse XML Profile' and browse to the downloaded config file.
Now, every time Intellij uses its auto-formatting features, it will conform to the standards in the config file. This can be done quickly with the shortcut Ctrl+Alt+L.
Eclipse
- Download the config (attached)
- Navigate to Window->Preferences
- Navigate to Java->Code Style->Formatter
- Click on Import and navigate to the downloaded config file
- Click Apply and Ok
Now, every time Eclipse uses its auto-formatting features, it will conform to the standards in the config file. This can be done quickly with the shortcut Ctrl+Shift+F.
Note: This profile might not work while formatting xml files. So go to Preferences -> XML -> Editor
I need to know the same alternative for Visual Studio Code. Please share any pointers !