J
Jeffrey Schwab
Is there a decent way to check whether an application's local
file-system is case sensitive?
file-system is case sensitive?
"Martin Lansler said:The 'equals' method in File can be used:
File f = new File(System.getProperty("java.home"));
File fLower = new File(f.getCanonicalPath().toLowerCase());
File fUpper = new File(f.getCanonicalPath().toUpperCase());
System.out.println("isCaseSensitive: " + !(fUpper.equals(fLower)));
Running on windows this gives false, should give true on Unix machines.
Regards,
Martin.
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.