- shortened_channel_name="${channel_name}"
- first_char=$(echo -n "${channel_name}" | cut -c1)
- if [ "${first_char}" = "#" ]; then
- shortened_channel_name=$(echo -n "${channel_name}" | cut -c2-)
- fi
- ln -sf "${logs_dir}" "${irclogs_dir}/${shortened_channel_name}"
+ ln -sfn "${logs_dir}" "${irclogs_dir}/${shortened_channel_name}"
+ htpasswd -c "${irclogs_pw_dir}/${shortened_channel_name}" "${login_user}" "${login_pw}"