src/Neutrino/Database/Migrations/MigrationCreator.php
public function create($name, $path, $table = null, $create = false)
    {
        $this->ensureMigrationDoesntAlreadyExist($name, $path);

        $stub = $this->getStubContent($table, $create);

        $populatedStub = $this->populateStub($name, $stub, $table);

        $path = $this->getPath($name, $path);

        file_put_contents($path, $populatedStub);

        return $path;
    }
public function create($name, $path, $table = null, $create = false)
    {
        $this->ensureMigrationDoesntAlreadyExist($name, $path);

        $stub = $this->getStubContent($table, $create);

        $populatedStub = $this->populateStub($name, $stub, $table);

        $path = $this->getPath($name, $path);

        file_put_contents($path, $populatedStub);

        return $path;
    }
Create a new migration at the given path.

@param  string $name
@param  string $path
@param  string $table
@param  bool   $create

@return string
@throws \Exception