laravel-backup icon indicating copy to clipboard operation
laravel-backup copied to clipboard

Backup flilename

Open longestdrive opened this issue 10 years ago • 1 comments

Can you confirm wqhether it's possible to append or prepend a filename to the backup. I'd like to be able to add the database name (from the config file) to the filename. I saw a closed issue relating to filenames but couldnt get it to work and assume not yet supported Thanks

longestdrive avatar Jan 23 '15 09:01 longestdrive

You may define the filepath+name as an argument for the command

protected function getArguments()
{
    return array(
        array('filename', InputArgument::OPTIONAL, 'Filename or -path for the dump.'),
    );
}

So

php artisan db:backup app/storage/dumps/YOURNAME.sql

stores with your specified name.

I'm probably pretty late, but maybe the issue gets cleared.

KuenzelIT avatar Jun 14 '15 22:06 KuenzelIT