Skip to content

Commit ae9f2a6

Browse files
committed
configure.{sh,fsx}: improve 1st time .NET run UX
1. Skip dotnet (Core) welcome message, otherwise it might be confusing to see it pop up when calling our configure script. 2. First time `dotnet fsi` is run, it takes a while to start (at least 20 or 30seconds on my VirtualBox VM running Ubuntu22.04.3) so it's better if that time is spent after printing ellipsis (...) so that it is more clear that one needs to wait.
1 parent b9ef32e commit ae9f2a6

File tree

2 files changed

+8
-5
lines changed

2 files changed

+8
-5
lines changed

configure.sh

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ RUNNER_ARG=invalid
77
REPL_CHECK_MSG="checking for a working F# REPL..."
88

99
if which dotnet >/dev/null 2>&1; then
10-
echo "$REPL_CHECK_MSG" $'found'
10+
echo -n "$REPL_CHECK_MSG"
1111
RUNNER_BIN=dotnet
1212
RUNNER_ARG=fsi
1313
else
@@ -35,7 +35,7 @@ else
3535
echo "$0" $'failed, please install "dotnet" first'
3636
exit 1
3737
else
38-
echo "$FSX_CHECK_MSG" $'found'
38+
echo -n "$FSX_CHECK_MSG"
3939
RUNNER_BIN=fsx
4040
RUNNER_ARG=
4141
fi
@@ -53,11 +53,11 @@ else
5353
cd scripts/fsx && ./configure.sh --prefix=$BIN_DIR && make install && cd ../..
5454
RUNNER_BIN="$BIN_DIR/bin/fsx"
5555
else
56-
echo "$FSX_CHECK_MSG" $'found'
56+
echo -n "$FSX_CHECK_MSG"
5757
RUNNER_BIN=fsx
5858
fi
5959
else
60-
echo "$REPL_CHECK_MSG" $'found'
60+
echo -n "$REPL_CHECK_MSG"
6161
RUNNER_BIN=fsharpi
6262
RUNNER_ARG="--define:LEGACY_FRAMEWORK"
6363
fi
@@ -73,4 +73,4 @@ if [ ! -z "${RUNNER_ARG}" ]; then
7373
echo -e "FsxRunnerArg=$RUNNER_ARG" >> scripts/build.config
7474
fi
7575
source scripts/build.config
76-
$RUNNER_BIN $RUNNER_ARG ./scripts/configure.fsx "$@"
76+
DOTNET_NOLOGO=true $RUNNER_BIN $RUNNER_ARG ./scripts/configure.fsx "$@"

scripts/configure.fsx

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,9 @@ let initialConfigFile, buildTool =
4040
Map.empty, buildTool
4141
| platform (* Unix *) ->
4242

43+
// because it comes from configure.sh's "Checking for a working F# REPL..."
44+
Console.WriteLine " found"
45+
4346
Process.ConfigCommandCheck ["make"] true true |> ignore
4447

4548
match Process.ConfigCommandCheck ["dotnet"] false true with

0 commit comments

Comments
 (0)