Skip to content
This repository was archived by the owner on Mar 29, 2019. It is now read-only.

Commit bd81716

Browse files
authored
Merge pull request #8 from kenhys/fix-on-appveyor
Fix problems to launch process
2 parents 82c01cb + 9e72da3 commit bd81716

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

powershell/install-mroonga.ps1

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,15 +23,16 @@ function Wait-UntilTerminate($cmdName) {
2323

2424
function Install-Mroonga($mariadbVer, $arch, $installSqlDir) {
2525
cd "mariadb-$mariadbVer-$arch"
26-
cmd /c "start .\bin\mysqld.exe"
26+
Start-Process .\bin\mysqld.exe
2727
Wait-UntilRunning mysqld
28-
cmd /c ".\bin\mysql.exe -uroot <$installSqlDir\install.sql"
29-
cmd /c ".\bin\mysqladmin.exe -uroot shutdown"
28+
Get-Content "$installSqlDir\install.sql" | .\bin\mysql.exe -uroot
29+
Start-Sleep -m 1000
30+
Start-Process .\bin\mysqladmin.exe -ArgumentList "-uroot shutdown"
3031
Wait-UntilTerminate mysqld
3132
cd ..
3233
}
3334

34-
$installSqlDir = "share\mroonga"
35+
$installSqlDir = ".\share\mroonga"
3536

3637
$platform = "win32", "winx64"
3738
foreach ($arch in $platform)

0 commit comments

Comments
 (0)