lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]

On Fri, Mar 28, 2014 at 11:31 AM, Jay Carlson <> wrote:

On Mar 28, 2014 3:23 AM, "steve donovan" <> wrote:
> On Thu, Mar 27, 2014 at 6:05 PM, Coda Highland <> wrote:
> > I didn't know about that, but he was actually talking about the other
> > way around -- make the interpreter ignore a leading > if you're
> > copy-pasting a session from an e-mail into the terminal window.
> And here is a patch for that case, specially for Dirk ;)

Aw, I was going to suggest he set his prompts to "; " and "--[[]] ". You still lose desk-calculatorization without your patch.

I never liked that readline history changed "=x" to "return x" but perhaps it had teaching value.


Nice idea. You can even throw in some ANSI escape sequences to make the prompt stand out:
$ lua -e '_PROMPT="\027[38;5;10m; \027[0m"' -i

I think > looks nicer than ; for a prompt though. This has me pondering the idea of hacking terminal emulators to add a text attribute that says "omit this when copying to clipboard". Although you might want to keep the prompts intact when showing examples.

What logic does 5.3's REPL use to not require the '=' anyway?

Sent from my Game Boy.