Skip to content

Commit 5c1dcc0

Browse files
committed
[local-preview] Failure with more specific information
Currently, When there is a failure at `checking_prerequisites` we don't actually propogate the issue resulting in confusion to the users. This PR updates the prettylog script to propogate the same as an error for the user to get more information Signed-off-by: Tarun Pothulapati <[email protected]>
1 parent 41d484f commit 5c1dcc0

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

install/preview/entrypoint.sh

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,6 @@ total_mem_kb=$(awk '/MemTotal:/ {print $2}' /proc/meminfo)
2727
if [ "${total_mem_kb}" -lt "${REQUIRED_MEM_KB}" ]; then
2828
echo "Gitpod local preview requires a system with at least 6GB of memory"
2929
exit 1
30-
else
31-
set -x
3230
fi
3331

3432
REQUIRED_CORES=4

install/preview/prettylog/main.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,8 @@ For more information about these limitation, please visit the local preview docu
6969
switch {
7070
case msg.Fail != "" && strings.Contains(line, msg.Fail):
7171
lastSpinner.Fail()
72-
next = true
72+
pterm.FgLightRed.Println("Failed with error: " + line)
73+
return
7374
case msg.Success != "" && strings.Contains(line, msg.Success):
7475
lastSpinner.Success()
7576
next = true

0 commit comments

Comments
 (0)