Skip to content

Commit

Permalink
scripts: remove unneeded fsx-legacy.bat
Browse files Browse the repository at this point in the history
This should have been done in:
524c92c
  • Loading branch information
knocte committed Aug 22, 2023
1 parent 524c92c commit 87e807e
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 14 deletions.
8 changes: 0 additions & 8 deletions scripts/fsx-legacy.bat

This file was deleted.

17 changes: 11 additions & 6 deletions scripts/make.fsx
Original file line number Diff line number Diff line change
Expand Up @@ -188,13 +188,18 @@ 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())

let assemblyExecutableExtension =
Expand Down Expand Up @@ -253,9 +258,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
Expand Down Expand Up @@ -324,14 +329,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
Expand Down
4 changes: 4 additions & 0 deletions scripts/runTests.fsx
Original file line number Diff line number Diff line change
Expand Up @@ -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()
Expand Down

0 comments on commit 87e807e

Please sign in to comment.