Fix for JAVA_HOME variable in OS X Yosemite

19 03 2015

In case you upgraded to OS X Yosemite and your JAVA_HOME variable in bash_profile no longer works, change/add the following:

export JAVA_HOME=`/usr/libexec/java_home -v 1.7`

Then, run source ~/.bash_profile and it should work from there.



Highlight Text In Powerpoint: 5 Creative Ideas

1 02 2015

Archiving this link as I will definitely use need this in the future.

Highlight Text In Powerpoint: 5 Creative Ideas.



Science concepts shown through GIFs

19 12 2014

Pretty cool gifs that’ll help you understand concepts visually:

20 Gifs That Teach You Science Concepts In Seconds



Java: Concatenate a string before the last occurrence of any character

10 12 2014

private String addToString(String source, char separator, String toBeInserted) {
int index = source.lastIndexOf(separator);
if(index >= 0 && index < source.length())
return source.substring(0, index) + toBeInserted + source.substring(index);
else
return null;
}



How to copy file permissions from one to another

5 12 2014

chmod `stat -f %A srcFile` dstFile

via Non Geek Recipes How to copy file permissions – nongeekrecipes.org.