Re: groovysh easily breaks
Sistemas Jaguar <[email protected]> Wed, 30 Apr 2025 12:46:57 +0000
| Newsgroups | gmane.comp.lang.groovy.user |
|---|---|
| Message-ID | <eeeRlS6je7Og8f7VGWAxnBsCWWIsnJLecLFNSfVvq7Zh1ih62g1dS0BKrZ88lFnFw3G1-0pIAC3QPGMTdUMSHfid4qxRt4zJU51IhU6AQGM=@proton.me> |
On Wednesday, April 30th, 2025 at 6:26 AM, Christopher Smith <[email protected]> wrote: > The number after the colon indicates that the shell sees unclosed constructs such as brackets, braces, or parentheses and is waiting for you to close them before executing. > > I did not know about :c, which is great to have! > > On Wed, Apr 30, 2025, 07:06 Sistemas Jaguar <[email protected]> wrote: > >> If an incorrect command is entered the REPL stops working: >> >> Groovy Shell (4.0.26, JVM: 1.8.0_432) >> Type ':help' or ':h' for help.-------------------------------------------------------------------------------------------------------- >> >> groovy:000> System.getProperty("java.version") >> ===> 1.8.0_432 >> groovy:000> println "Hello" >> Hello===> null >> >> groovy:000> a=[ >> groovy:001> println "Hello" >> >> groovy:002> System.getProperty("java.version") >> groovy:003> a=[:] >> groovy:004> >> >> After 'a=[' other than commands (:command syntax), the REPL seens to break requiring a restart, which is frustrating and time consuming to say the least. >> >> Am I missing something? >> >> Thanks. >> >> Linux kiwi 6.1.0-34-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.135-1 (2025-04-25) x86_64 GNU/Linux My bad, thought I had tested by closing the command at a new line (i.e. by means of ':]'). Did not know about ':c', no doubt it will be very useful. Thanks for your help!