<commit_before><?php
/**
 * This file is part of the Laravel Auditing package.
 *
 * @author     <NAME> <<EMAIL>>
 * @author     <NAME>  <<EMAIL>>
 * @author     <NAME> <<EMAIL>>
 * @copyright  2015-2018
 *
 * For the full copyright and license information,
 * please view the LICENSE.md file that was distributed
 * with this source code.
 */

namespace OwenIt\Auditing;

use Illuminate\Support\ServiceProvider;
use OwenIt\Auditing\Console\AuditDriverMakeCommand;
use OwenIt\Auditing\Contracts\Auditor;

class AuditingServiceProvider extends ServiceProvider
{
    /**
     * {@inheritdoc}
     */
    protected $defer = true;

    /**
     * Bootstrap the service provider.
     *
     * @return void
     */
    public function boot()
    {
        $config = __DIR__.'/../config/audit.php';
        $migration = __DIR__.'/../database/migrations/audits.stub';

        $this->publishes([
            $config => config_path('audit.php'),
        ], 'config');

        $this->publishes([
            $migration => database_path(sprintf('migrations/%s_create_audits_table.php', date('Y_m_d_His'))),
        ], 'migrations');

        $this->mergeConfigFrom($config, 'audit');
    }

    /**
     * Register the service provider.
     *
     * @return void
     */
    public function register()
    {
        $this->commands([
            AuditDriverMakeCommand::class,
        ]);
<commit_msg>fix(AuditingServiceProvider): use base_path() instead of config_path(), for Lumen compatibility<commit_after><?php
/**
 * This file is part of the Laravel Auditing package.
 *
 * @author     <NAME> <<EMAIL>>
 * @author     <NAME>  <<EMAIL>>
 * @author     <NAME> <<EMAIL>>
 * @copyright  2015-2018
 *
 * For the full copyright and license information,
 * please view the LICENSE.md file that was distributed
 * with this source code.
 */

namespace OwenIt\Auditing;

use Illuminate\Support\ServiceProvider;
use OwenIt\Auditing\Console\AuditDriverMakeCommand;
use OwenIt\Auditing\Contracts\Auditor;

class AuditingServiceProvider extends ServiceProvider
{
    /**
     * {@inheritdoc}
     */
    protected $defer = true;

    /**
     * Bootstrap the service provider.
     *
     * @return void
     */
    public function boot()
    {
        $config = __DIR__.'/../config/audit.php';
        $migration = __DIR__.'/../database/migrations/audits.stub';

        // Lumen lacks a config_path() helper, so we use base_path()
        $this->publishes([
            $config => base_path('config/audit.php'),
        ], 'config');

        $this->publishes([
            $migration => database_path(sprintf('migrations/%s_create_audits_table.php', date('Y_m_d_His'))),
        ], 'migrations');

        $this->mergeConfigFrom($config, 'audit');
    }

    /**
     * Register the service provider.
     *
     * @return void
     */
    public function register()
    {
        $this->commands([
            AuditDriverMakeCommand::class,
        ]);

{'fraction_non_alphanumeric': 0.1380013596193066, 'fraction_numerical': 0.005438477226376614, 'mean_word_length': 2.5457831325301203, 'pattern_counts': {'":': 0, '<': 23, '<?xml version=': 0, '>': 33, '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': '4099579', 'n_tokens_mistral': 893, 'n_tokens_neox': 879, 'n_words': 199}