From 7a5f9653477f4cbc75dc38afc32ae6dc3ccbe942 Mon Sep 17 00:00:00 2001 From: Guillaume Martres <smarter@ubuntu.com> Date: Mon, 22 Feb 2021 17:51:42 +0100 Subject: [PATCH] fix repl multiline instructions on macOS --- labs/example-lab.md | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/labs/example-lab.md b/labs/example-lab.md index 040911c..8b7e1f8 100644 --- a/labs/example-lab.md +++ b/labs/example-lab.md @@ -217,8 +217,7 @@ scala> max(List(1,3,2)) res1: Int = 3 ``` -You can enter a multiline expression in the REPL by using `Alt+Enter` -(`Option+Enter` on macOS) instead of `Enter`: +You can enter a multiline expression in the REPL by using `Alt+Enter` instead of `Enter`: ```scala scala> if 1 == 1 then @@ -228,6 +227,10 @@ scala> if 1 == 1 then val res0: String = a ``` +(on macOS, first go to `Terminal -> Preference -> Profiles -> Keyboard` and then +select `Use Option as Meta key`, then `Option+Enter` will work for multiline +expressions.) + In order to exit the Scala REPL and go back to sbt, type `Ctrl+D`. ### The worksheet mode -- GitLab