« Retour - Using IntelliJ...

Arranging code with IntelliJ

Étiquettes: intellij productivity

Rearranger is a nice IntelliJ plugin that may help with arranging code according to Liferay development style. It can organize methods, variables constructors... as defined in user rules.

You can download these rules from this link and import them using Configuration tab option (tested on IntelliJ 13 and Rearranger 5.5)

Here is the screenshot of rules list in action:

Rules can be also exported to a file and therefore shared among developers

Once when rule patterns are generated (tab 'General'), you can invoke Rearranger on current file simply by a hotkey or from a quick-menu.

Other settings #

\n// (-{30} FIELDS -{30}|-{26} ((STATIC|OTHER) METHOD|ENUMERATION|INNER CLASSE)S -{26}|-{27} (CONSTRUCTORS|main\(\) method) -{27}|-{21} (GETTER / SETTER METHODS|Interface [A-Za-z0-9_]+) -{21}|-{24} (CANONICAL|INTERFACE) METHODS -{24})\n

On Spacing and Extracted method tabs everything is unchecked.

Moyenne (0 Voter)
L'estimation moyenne est de 0.0 étoiles sur 5.
Commentaires
Réponses Auteur Données
Hey Igor Thx for the post. Do you think you... Everest Liu 14 mars 2014 05:50
You can download the settings file from here: ... Jose M. Navarro 14 mars 2014 05:50

Everest Liu
Hey Igor

Thx for the post. Do you think you could provide a settings file so we can adhere to the Liferay standards? Thx
Publié le 14/03/14 05:50.
You can download the settings file from here:

https://www.liferay.com/es/community/wiki?p_auth=I9C4C1Qy&p_p_id=36&p_p_lifecycl­e=1&p_p_state=exclusive&p_p_mode=view&p_p_col_id=column-2&p_p_col_count=1&_36_st­ruts_action=%2Fwiki%2Fget_page_attachment&p_r_p_185834411_nodeId=1071674&p_r_p_1­85834411_title=Arranging+code+with+IntelliJ&_36_fileName=liferay-rearranger-conf­ig
Publié le 14/03/14 05:50 en réponse à Everest Liu.