(scripts) Update javadoc script

Fix indentation, update comments