Java Ninja Chronicles By Norris Shelton

Things I learned in the pursuit of code

Intellij IDEA doesn’t show hidden files in the file chooser dialog on Mac OS/X. This can be frustrating when you are trying to find files that are always in a hidden directory, such as Maven files. There are two ways around this.

This will enable it for the current window

ctrl + shift + .

There is another solution, but it involves editing the registry. Hit the following keys to access the Find Action menu.

cmd + shift + a

Once there, scroll down to ide.mac.file.chooser.show.hidden.files. Check the checkbox and select Close and away you go.

July 28th, 2015

Posted In: IntelliJ, java ninja, Javaninja, Mac, OS/X

Tags: , , ,

One Comment

The servlet 3.0 spec defines a way to share webapp JSP resources via a dependent jar (See Servlet 3.0 spec, section 10.5)

If you have a Maven dependency that is a jar, you can package resources and have them available to webapps that use them as a dependency.

To share, /css/test.css, you need to place it in:
/mavenModule/src/main/resources/META-INF/resources/css/test.css

Any webapp that depends on that jar can access /css/test.css as if it was in the root of it’s own webapp.

<link rel="stylesheet" type="text/css" href="<c:url value="/css/test.css" />">

Caveat, IntelliJ does not resolve /css/test.css as being within the current webapp. There was a ticket that was filed in 2011, but it doesn’t appear that it will ever be fixed.

Note, that if you are trying to use the included file as a tag file, it will need to have /WEB-INF/tags at the front of the included path.

January 24th, 2014

Posted In: IntelliJ, Maven, Servlet Spec

Leave a Comment

Do you ever wish you can go in and change the number of days of local history to keep? Well, you are in luck.

CTRL+ ALT + SHIFT + /

The maintenance panel is displayed. Pick “registry”. Scroll down to the bottom and look for localHistory.daysToKeep. It defaults to 5. Change away!!!

January 20th, 2011

Posted In: IntelliJ

Leave a Comment

LinkedIn Auto Publish Powered By : XYZScripts.com