diff --git a/scripts/fsx-legacy.bat b/scripts/fsx-legacy.bat deleted file mode 100644 index d2157e0..0000000 --- a/scripts/fsx-legacy.bat +++ /dev/null @@ -1,8 +0,0 @@ -@ECHO OFF -SET "FSXFSX=%ProgramW6432%\fsx\fsx.exe" - -IF NOT EXIST "%FSXFSX%" ( - ECHO "%FSXFSX% not found" && EXIT /b 1 -) - -"%FSXFSX%" %* diff --git a/scripts/make.fsx b/scripts/make.fsx index 731506f..084f177 100644 --- a/scripts/make.fsx +++ b/scripts/make.fsx @@ -188,12 +188,15 @@ let fsxInstallationDir = #if !LEGACY_FRAMEWORK let fsxBat = Path.Combine(ScriptsDir.FullName, "fsx.bat") |> FileInfo -#else -let fsxBat = Path.Combine(ScriptsDir.FullName, "fsx-legacy.bat") |> FileInfo -#endif let fsxBatDestination = Path.Combine(fsxInstallationDir.FullName, "fsx.bat") |> FileInfo +let fsxInstalledExecutable = fsxBatDestination +#else +let fsxExeDestination = + Path.Combine(fsxInstallationDir.FullName, "fsx.exe") |> FileInfo +let fsxInstalledExecutable = fsxExeDestination +#endif let maybeTarget = GatherTarget(Misc.FsxOnlyArguments()) @@ -253,9 +256,9 @@ let Install(isReinstall: bool) = Path.Combine(finalReleaseFolderPath, "fsx.runtimeconfig.json"), Path.Combine(fsxInstallationDir.FullName, "fsx.runtimeconfig.json") ) -#endif File.Copy(fsxBat.FullName, fsxBatDestination.FullName) +#endif let fsdkInstallDir = Path.Combine(fsxInstallationDir.FullName, "Fsdk") |> DirectoryInfo @@ -324,14 +327,14 @@ match maybeTarget with | Some "check" -> // FIXME: contributor should be able to run 'make check' before 'make install' - if not fsxBatDestination.Exists then + if not fsxInstalledExecutable.Exists then Console.WriteLine "install first" Environment.Exit 1 let testProcess = Process.Execute( { - Command = fsxBatDestination.FullName + Command = fsxInstalledExecutable.FullName Arguments = Path.Combine(ScriptsDir.FullName, "runTests.fsx") }, Echo.All diff --git a/scripts/runTests.fsx b/scripts/runTests.fsx index 9bc82b9..2d46f47 100755 --- a/scripts/runTests.fsx +++ b/scripts/runTests.fsx @@ -31,7 +31,11 @@ let GetFsxWindowsLauncher() = let fsxWinInstallationDir = Path.Combine(programFiles.FullName, "fsx") |> DirectoryInfo +#if !LEGACY_FRAMEWORK Path.Combine(fsxWinInstallationDir.FullName, "fsx.bat") |> FileInfo +#else + Path.Combine(fsxWinInstallationDir.FullName, "fsx.exe") |> FileInfo +#endif let CreateCommand(executable: FileInfo, args: string) = let platform = Misc.GuessPlatform()