Apple in the latest releases of OS X removed Java from default installation so for my needs I installed JDK from Oracle's website.
~ java -version java version "1.7.0_07" Java(TM) SE Runtime Environment (build 1.7.0_07-b10) Java HotSpot(TM) 64-Bit Server VM (build 23.3-b01, mixed mode)
It works fine in Terminal and for for my apps but when I launch any app for mac written in Java I get typical "To open X you need to install Java SE 6 runtime. Would you like to install one now?" message.
Is there a way to tell OS X to launch Java apps with java I installed without installing another one? I'm trying to run IntelliJ IDEA 12.