Skip to content

Commit

Permalink
replace puli (#7)
Browse files Browse the repository at this point in the history
  • Loading branch information
wachterjohannes authored Dec 2, 2020
1 parent 143afe3 commit bcb79b7
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 20 deletions.
17 changes: 10 additions & 7 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,11 @@
"description": "Nanando-Plugin to backup mysql databases",
"type": "plugin",
"require": {
"symfony/process": "^3.0"
"symfony/process": "^5.2"
},
"require-dev": {
"nanbando/core": "^0.1|dev-master",
"dflydev/embedded-composer": "@dev",
"puli/repository": "@dev",
"puli/discovery": "@dev",
"puli/url-generator": "@dev",
"puli/manager": "@dev",

"phpunit/phpunit": "^5.3"
},
Expand All @@ -24,7 +20,14 @@
"authors": [
{
"name": "Johannes Wachter",
"email": "johannes[email protected]"
"email": "johannes@sulu.io"
}
]
],
"extra": {
"nanbando": {
"bundle-classes": [
"Nanbando\\Plugin\\Mysql\\NanbandoMysqlBundle"
]
}
}
}
11 changes: 0 additions & 11 deletions puli.json

This file was deleted.

4 changes: 2 additions & 2 deletions src/MysqlPlugin.php
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ public function backup(Filesystem $source, Filesystem $destination, Database $da
);

$tempFile = $this->temporaryFileSystem->createTemporaryFile('mysql');
$process = new Process($this->getExportCommand($parameter, $tempFile));
$process = Process::fromShellCommandline($this->getExportCommand($parameter, $tempFile));
$process->run();

while ($process->isRunning()) {
Expand Down Expand Up @@ -84,7 +84,7 @@ public function restore(
$tempFile = $this->temporaryFileSystem->createTemporaryFile('mysql');
file_put_contents($tempFile, $source->read('dump.sql'));

$process = new Process($this->getImportCommand($parameter, $tempFile));
$process = Process::fromShellCommandline($this->getImportCommand($parameter, $tempFile));
$process->run();

while ($process->isRunning()) {
Expand Down

0 comments on commit bcb79b7

Please sign in to comment.