<commit_before><?php
namespace Src;

use Phar;

class BuildPhar {
    public static function build(){
        ini_set("phar.readonly", 0);

        if(is_file('wppot.phar')){
            unlink('wppot.phar');
        }

        // COMPILE
        $phar = new Phar("wppot.phar");
        $phar->startBuffering();

        $defaultStub = $phar->createDefaultStub('main.php');

        $phar->buildFromDirectory(dirname(__DIR__), '/(main\.php|vendor|src)/');

        $stub = "#!/usr/bin/env php \n" . $defaultStub;

        $phar->setStub($stub);

        $phar->stopBuffering();
    }
}<commit_msg>Fix sonar issues<commit_after><?php
namespace Src;

use Phar;

class BuildPhar {
    const pharname = "wppot.phar";

    public static function build(){
        ini_set("phar.readonly", 0);

        if(is_file(BuildPhar::pharname)){
            unlink(BuildPhar::pharname);
        }

        // COMPILE
        $phar = new Phar(BuildPhar::pharname);
        $phar->startBuffering();

        $defaultStub = $phar->createDefaultStub('main.php');

        $phar->buildFromDirectory(dirname(__DIR__), '/(main\.php|vendor|src)/');

        $stub = "#!/usr/bin/env php \n" . $defaultStub;

        $phar->setStub($stub);

        $phar->stopBuffering();
    }
}
{'fraction_non_alphanumeric': 0.1722488038277512, 'fraction_numerical': 0.001594896331738437, 'mean_word_length': 2.447802197802198, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 13, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1500805', 'n_tokens_mistral': 450, 'n_tokens_neox': 437, 'n_words': 67}