add licence to bash script and beautify headers