add java environment checker and escape special charachter