views:

318

answers:

2

Hi,

I can't seem to get "Reformat Code" to work on my mac version of Intellij. I'm using a 30 day trial.

Update & Clarification;

It doesn't do anything, there is no reformatting done at all.

Thanks

A: 

Works fine for me. Maybe you are using a file type not being supported to reformat. But for usability the reformat option should be deactivated in that case. You may contact the IntelliJ IDEA team (and hope to get service for your trial). Or if you think that it's a bug, file a report or make an enhancement request.

Markus Lux
A: 

Turns out I had an issue

I had a directory structure which contained "Source" such as

/my/Path/To/**Source**/My/web/Project/Source/

This confused Intellij, which prevented it from reading my directory structure correctly. Because of this, my real "source" directory wasn't identified. Without my *.java files stored within a defined "source" directory, Intellij didn't know how to format my files. I had incorrectly assumed that Intellij would know simply by the file extension.

Roy Rico