The base_path function returns the fully qualified path to your application's root directory. You may also use the base_path function to generate a fully qualified path to a given file relative to the project root directory:
<?php $path = base_path();

$path = base_path('vendor/bin');
<?php         $this->app->singleton(Flare::class, function () {

            $client = new Flare($this->app->get('flare.http'), new LaravelContextDetector, $this->app);

            $client->applicationPath(base_path());

            $client->stage(config('app.env'));



            return $client;
<?php     protected function getConfigFileLocation(): ?string

    {

        $configFullPath = base_path().DIRECTORY_SEPARATOR.'.ignition';



        if (file_exists($configFullPath)) {

            return $configFullPath;
<?php     protected function command($command)

    {

        $process = (new ReflectionClass(Process::class))->hasMethod('fromShellCommandline')

            ? Process::fromShellCommandline($command, base_path())

            : new Process($command, base_path());



        $process->run();
<?php     {

        $process = (new ReflectionClass(Process::class))->hasMethod('fromShellCommandline')

            ? Process::fromShellCommandline($command, base_path())

            : new Process($command, base_path());



        $process->run();
<?php     protected function envFileExists(): bool

    {

        return file_exists(base_path('.env'));

    }



    protected function isAccessDeniedCode($code): bool
<?php     public function run(array $parameters = [])

    {

        if (! file_exists(base_path('.env'))) {

            return;

        }
<?php     protected function ensureLineExists(string $key, string $value)

    {

        $envPath = base_path('.env');



        $envLines = array_map(function (string $envLine) use ($value, $key) {

            return Str::startsWith($envLine, $key)
<?php     public function __construct(?string $autoloaderPath = null)

    {

        $autoloaderPath = $autoloaderPath ?? base_path('/vendor/autoload.php');



        if (file_exists($autoloaderPath)) {

            $this->composer = require $autoloaderPath;