Skip to content

Commit

Permalink
fsxc: if fsx, show yourScriptOptions in usage
Browse files Browse the repository at this point in the history
As opposed to fsxc, fsx accepts options for the script being
invoked, so to make it crystal clear we add them in
PrintUsage().
  • Loading branch information
knocte committed Aug 23, 2023
1 parent b6d8818 commit b140cba
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions fsxc/Fsxc.fs
Original file line number Diff line number Diff line change
Expand Up @@ -61,10 +61,10 @@ module Program =
#endif

let PrintUsage(invocationType: ProgramInvocationType) =
let programInvocation =
let programInvocation, scriptOptions =
match invocationType with
| FsxcPureInvocation -> "fsxc"
| FsxLauncherScript -> "fsx"
| FsxcPureInvocation -> "fsxc", String.Empty
| FsxLauncherScript -> "fsx", " [yourScriptOptions]"

Console.WriteLine()

Expand All @@ -77,9 +77,10 @@ module Program =

Console.WriteLine(
sprintf
"Usage: %s%s [OPTION] yourScript.fsx"
"Usage: %s%s [OPTION] yourScript.fsx%s"
dotnetToolPrefix
programInvocation
scriptOptions
)

Console.WriteLine()
Expand Down

0 comments on commit b140cba

Please sign in to comment.