<commit_before><?php

# Try to create directories.
$fail = FALSE;
$cwd = getcwd();
if (!mkdir($cwd.'/'.$work_dir))      $fail = TRUE;
if (!mkdir($cwd.'/'.$work_temp_dir)) $fail = TRUE;
if (!mkdir($cwd.'/'.$diff_dir))      $fail = TRUE;
if (!mkdir($cwd.'/'.$del_dir))       $fail = TRUE;

# Answer according to success.
if ($fail)   $msg = 'PlomWiki Setup failed. Something is wrong!';
else       { $msg = 'PlomWiki Setup successful. Reload!'; unlink($setup_file); }

# Final HTML.
echo $html_start.'PlomWiki Setup</title>
</head>
<body>

<h1>PlomWiki Setup</h1>

<p><strong>'; echo $msg;
echo '</strong></p>'.$html_end;

exit();<commit_msg>Repaired HTML generated by setup.php<commit_after><?php

# Try to create directories.
$fail = FALSE;
$cwd = getcwd();
if (!mkdir($cwd.'/'.$work_dir))      $fail = TRUE;
if (!mkdir($cwd.'/'.$work_temp_dir)) $fail = TRUE;
if (!mkdir($cwd.'/'.$diff_dir))      $fail = TRUE;
if (!mkdir($cwd.'/'.$del_dir))       $fail = TRUE;

# Answer according to success.
if ($fail)   $msg = 'PlomWiki Setup failed. Something is wrong!';
else       { $msg = 'PlomWiki Setup successful. Reload!'; unlink($setup_file); }

# Final HTML.
echo $html_start.'PlomWiki Setup</title>'."\n".'</head>'."\n".'<body>'."\n\n".
     '<h1>PlomWiki Setup</h1>'."\n\n".'<p><strong>'.$msg.'</strong></p>'."\n\n".
                                                       '</body>'."\n".'</html>';

exit();
{'fraction_non_alphanumeric': 0.23487544483985764, 'fraction_numerical': 0.0028469750889679717, 'mean_word_length': 3.2095808383233533, 'pattern_counts': {'":': 0, '<': 25, '<?xml version=': 0, '>': 23, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1107433', 'n_tokens_mistral': 529, 'n_tokens_neox': 531, 'n_words': 117}