src/Charcoal/App/AppConfig.php
public function setBasePath($path)
    {
        if ($path === null) {
            throw new InvalidArgumentException(
                'The base path is required.'
            );
        }

        if (!is_string($path)) {
            throw new InvalidArgumentException(
                'The base path must be a string'
            );
        }

        $this->basePath = rtrim(realpath($path), '\\/').DIRECTORY_SEPARATOR;
        return $this;
    }
public function setBasePath($path)
    {
        if ($path === null) {
            throw new InvalidArgumentException(
                'The base path is required.'
            );
        }

        if (!is_string($path)) {
            throw new InvalidArgumentException(
                'The base path must be a string'
            );
        }

        $this->basePath = rtrim(realpath($path), '\\/').DIRECTORY_SEPARATOR;
        return $this;
    }
public function setBasePath ( $ path ) { if ( $ path === null ) { throw new InvalidArgumentException ( 'The base path is required.' ) ; } if ( ! is_string ( $ path ) ) { throw new InvalidArgumentException ( 'The base path must be a string' ) ; } $ this -> basePath = rtrim ( realpath ( $ path ) , '\\/' ) . DIRECTORY_SEPARATOR ; return $ this ; }
Set the application's absolute root path.

Resolves symlinks with realpath() and ensure trailing slash.

@param  string $path The absolute path to the application's root directory.
@throws InvalidArgumentException If the argument is not a string.
@return self
Set the application s absolute root path .