New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
console: support line carrying with backslash #4317
Comments
OKriw
pushed a commit
that referenced
this issue
Apr 14, 2020
When using interactive console(stdin) instead of \set delimiter <delimiter> with "\", "\" in the end if line can be used. The patch enables "\" only for REPL over stdin. I have troubles to write tests for stdin input, because in case we attach to the console (remote or to self) another read (console_read) is used. And in this case I do not think that we need support backslash, because we stop reading till "\n" or "\r". Another problem that I have faced is testing (I have tried remote instance, console over socket and i little bit of popen. However, all this test take advantage of console_read and do not touch local_read. If you have any ideas how to test interactive console within test-run, please share. Closes #4317
OKriw
pushed a commit
that referenced
this issue
Jun 3, 2020
When using interactive console(stdin) instead of \set delimiter <delimiter> with "\", "\" in the end if line can be used. Closes #4317
OKriw
pushed a commit
that referenced
this issue
Jun 3, 2020
When using interactive console(stdin) instead of \set delimiter <delimiter> with "\", "\" in the end if line can be used. Closes #4317
OKriw
pushed a commit
that referenced
this issue
Jun 10, 2020
When using interactive console(stdin) instead of \set delimiter <delimiter> with "\", "\" in the end if line can be used. Closes #4317
OKriw
pushed a commit
that referenced
this issue
Jul 8, 2020
When using interactive console one has to explicitly set delimiter different from newline ('\n') symbol before this patch. The changes make possible to split console input into multiple lines via backslash ('\\') at the end of the line instead of setting a delimiter. Local console is impossible to test with a pipe or tatantool interactive mode. The problem with interactive mode (-i) is that the flag that sets it, does not influence the isatty() check, while startup script is executed (#5064). To overload this check and test the local console patch adds isatty lib. Closes #4317
Lord-KA
added a commit
to Lord-KA/tarantool
that referenced
this issue
Jul 4, 2022
Local console is impossible to test with a pipe or tarantool interactive mode. The problem with interactive mode (-i) is that the flag that sets it, does not influence the isatty() check, while startup script is executed (tarantool#5064). To overload this check and test the local console isatty lib was added. Co-Authored-By: Olga <arkholga@tarantool.org> Closes tarantool#4317 @TarantoolBot document Title: introduce line carrying slash When using interactive console(stdin) instead of `\set delimiter "\"`, slash at the end of the line can be used. Works on both server and client side. Consider the example: ``` tarantool> a = 10 \ > + 12 --- ... tarantool> a --- - 22 ... ```
Lord-KA
added a commit
to Lord-KA/tarantool
that referenced
this issue
Jul 4, 2022
Local console is impossible to test with a pipe or tarantool interactive mode. The problem with interactive mode (-i) is that the flag that sets it, does not influence the isatty() check, while startup script is executed (tarantool#5064). To overload this check and test the local console isatty lib was added. Co-authored-by: Olga <arkholga@tarantool.org> Closes tarantool#4317 @TarantoolBot document Title: introduce line carrying slash When using interactive console(stdin) instead of `\set delimiter "\"`, slash at the end of the line can be used. Works on both server and client side. Consider the example: ``` tarantool> a = 10 \ > + 12 --- ... tarantool> a --- - 22 ... ```
Lord-KA
added a commit
to Lord-KA/tarantool
that referenced
this issue
Jul 4, 2022
Local console is impossible to test with a pipe or tarantool interactive mode. The problem with interactive mode (-i) is that the flag that sets it, does not influence the isatty() check, while startup script is executed (tarantool#5064). To overload this check and test the local console isatty lib was added. Co-authored-by: Olga <arkholga@tarantool.org> Closes tarantool#4317 @TarantoolBot document Title: introduce line carrying slash When using interactive console(stdin) instead of `\set delimiter "\"`, slash at the end of the line can be used. Works on both server and client side. Consider the example: ``` tarantool> a = 10 \ > + 12 --- ... tarantool> a --- - 22 ... ```
Lord-KA
added a commit
to Lord-KA/tarantool
that referenced
this issue
Jul 4, 2022
Local console is impossible to test with a pipe or tarantool interactive mode. The problem with interactive mode (-i) is that the flag that sets it, does not influence the isatty() check, while startup script is executed (tarantool#5064). To overload this check and test the local console isatty lib was added. Co-authored-by: Olga <arkholga@tarantool.org> Closes tarantool#4317 @TarantoolBot document Title: introduce line carrying slash When using interactive console(stdin) instead of `\set delimiter "\"`, slash at the end of the line can be used. Works on both server and client side. Consider the example: ``` tarantool> a = 10 \ > + 12 --- ... tarantool> a --- - 22 ... ``` FreeBSD treats escaped chars differently than linux, thus when using printf the escaping must be escaped too. For example: ```BSD ~ printf "local a = 0 \\\\\nfor i = 1, 10 do\\\na = a + i\\\nend \\\\\nprint(a)" | | LD_PRELOAD=./test/libisatty.so ./src/tarantool ``` instead of ```linux ~ printf "local a = 0 \\\nfor i = 1, 10 do\na = a + i\nend \\\nprint(a)" | | LD_PRELOAD=./test/libisatty.so ./src/tarantool ```
Lord-KA
added a commit
to Lord-KA/tarantool
that referenced
this issue
Jul 4, 2022
Local console is impossible to test with a pipe or tarantool interactive mode. The problem with interactive mode (-i) is that the flag that sets it, does not influence the isatty() check, while startup script is executed (tarantool#5064). To overload this check and test the local console isatty lib was added. Co-authored-by: Olga <arkholga@tarantool.org> Closes tarantool#4317 @TarantoolBot document Title: introduce line carrying slash When using interactive console(stdin) instead of `\set delimiter "\"`, slash at the end of the line can be used. Works on both server and client side. Consider the example: ``` tarantool> a = 10 \ > + 12 --- ... tarantool> a --- - 22 ... ``` FreeBSD treats escaped chars differently than linux, thus when using printf the escaping must be escaped too. For example: ```BSD ~ printf "local a = 0 \\\\\nfor i = 1, 10 do\\\na = a + i\\\nend \\\\\nprint(a)" | | LD_PRELOAD=./test/libisatty.so ./src/tarantool ``` instead of ```linux ~ printf "local a = 0 \\\nfor i = 1, 10 do\na = a + i\nend \\\nprint(a)" | | LD_PRELOAD=./test/libisatty.so ./src/tarantool ```
Lord-KA
added a commit
to Lord-KA/tarantool
that referenced
this issue
Jul 4, 2022
Local console is impossible to test with a pipe or tarantool interactive mode. The problem with interactive mode (-i) is that the flag that sets it, does not influence the isatty() check, while startup script is executed (tarantool#5064). To overload this check and test the local console isatty lib was added. Co-authored-by: Olga Arkhangelskaia <arkholga@tarantool.org> Closes tarantool#4317 @TarantoolBot document Title: introduce line carrying slash When using interactive console(stdin) instead of `\set delimiter "\"`, slash at the end of the line can be used. Works on both server and client side. Consider the example: ``` tarantool> a = 10 \ > + 12 --- ... tarantool> a --- - 22 ... ``` FreeBSD treats escaped chars differently than linux, thus when using printf the escaping must be escaped too. For example: ```BSD ~ printf "local a = 0 \\\\\nfor i = 1, 10 do\\\na = a + i\\\nend \\\\\nprint(a)" | | LD_PRELOAD=./test/libisatty.so ./src/tarantool ``` instead of ```linux ~ printf "local a = 0 \\\nfor i = 1, 10 do\na = a + i\nend \\\nprint(a)" | | LD_PRELOAD=./test/libisatty.so ./src/tarantool ```
Lord-KA
added a commit
to Lord-KA/tarantool
that referenced
this issue
Jul 6, 2022
When using interactive console(stdin) instead of `\set delimiter '\'`, slash at the end of the line can be used. Works on both server and client side. Local console is impossible to test with a pipe or tarantool interactive mode. The problem with interactive mode (-i) is that the flag that sets it, does not influence the isatty() check, while startup script is executed (tarantool#5064). To overload this check and test the local console isatty lib was added. Co-authored-by: Olga Arkhangelskaia <arkholga@tarantool.org> Closes tarantool#4317 @TarantoolBot document Title: introduce line carrying slash Now we can use multiline commands with lines ending with '\' by default. Works only without a set delimiter. Consider the example: ``` tarantool> a = 10 \ > + 12 --- ... tarantool> a --- - 22 ... ```
Lord-KA
added a commit
to Lord-KA/tarantool
that referenced
this issue
Jul 11, 2022
When using interactive console(stdin) instead of `\set delimiter '\'`, slash at the end of the line can be used. Works on both server and client side. Co-authored-by: Olga Arkhangelskaia <arkholga@tarantool.org> Closes tarantool#4317 Requires tarantool#7357 @TarantoolBot document Title: introduce line carrying slash Now we can use multiline commands with lines ending with '\' by default. Works only without a set delimiter. Consider the example: ``` tarantool> a = 10 \ > + 12 --- ... tarantool> a --- - 22 ... ```
Lord-KA
added a commit
to Lord-KA/tarantool
that referenced
this issue
Jul 11, 2022
When using interactive console(stdin) instead of `\set delimiter '\'`, slash at the end of the line can be used. Works on both server and client side. Co-authored-by: Olga Arkhangelskaia <arkholga@tarantool.org> Closes tarantool#4317 Requires tarantool#7357 @TarantoolBot document Title: introduce line carrying slash Now we can use multiline commands with lines ending with '\' by default. Works only without a set delimiter. Consider the example: ``` tarantool> a = 10 \ > + 12 --- ... tarantool> a --- - 22 ... ```
Lord-KA
added a commit
to Lord-KA/tarantool
that referenced
this issue
Jul 14, 2022
When using interactive console(stdin) instead of `\set delimiter '\'`, slash at the end of the line can be used. Works on both server and client side. Co-authored-by: Olga Arkhangelskaia <arkholga@tarantool.org> Closes tarantool#4317 Requires tarantool#7357 @TarantoolBot document Title: introduce line carrying slash Now we can use multiline commands with lines ending with '\' by default. Works only when console is in lua mode and without a set delimiter. Consider the example: ``` tarantool> a = 10 \ > + 12 --- ... tarantool> a --- - 22 ... ```
Lord-KA
added a commit
to Lord-KA/tarantool
that referenced
this issue
Jul 14, 2022
When using interactive console(stdin) instead of `\set delimiter '\'`, slash at the end of the line can be used. Works on both server and client side. Co-authored-by: Olga Arkhangelskaia <arkholga@tarantool.org> Closes tarantool#4317 Requires tarantool#7357 @TarantoolBot document Title: introduce line carrying slash Now we can use multiline commands with lines ending with '\' by default. Works only when console is in lua mode and without a set delimiter. Consider the example: ``` tarantool> a = 10 \ > + 12 --- ... tarantool> a --- - 22 ... ```
Lord-KA
added a commit
to Lord-KA/tarantool
that referenced
this issue
Jul 20, 2022
When using interactive console(stdin) instead of `\set delimiter '\'`, slash at the end of the line can be used. Works on both server and client side. Co-authored-by: Olga Arkhangelskaia <arkholga@tarantool.org> Closes tarantool#4317 Requires tarantool#7357 @TarantoolBot document Title: introduce line carrying slash Now we can use multiline commands with lines ending with '\' by default. Works only when console is in lua mode and without a set delimiter. Consider the example: ``` tarantool> a = 10 \ > + 12 --- ... tarantool> a --- - 22 ... ```
Lord-KA
added a commit
to Lord-KA/tarantool
that referenced
this issue
Aug 1, 2022
When using interactive console(stdin) instead of `\set delimiter '\'`, slash at the end of the line can be used. Works on both server and client side. Co-authored-by: Olga Arkhangelskaia <arkholga@tarantool.org> Closes tarantool#4317 Requires tarantool#7357 @TarantoolBot document Title: introduce line carrying slash Now we can use multiline commands with lines ending with '\' by default. Works only when console is in lua mode and without a set delimiter. Consider the example: ``` tarantool> a = 10 \ > + 12 --- ... tarantool> a --- - 22 ... ```
Lord-KA
added a commit
to Lord-KA/tarantool
that referenced
this issue
Feb 27, 2023
Continuation marker can be set up with `\set continuation` command. Works on both server and client side in any language. Closes tarantool#4317 Requires tarantool#7357 @TarantoolBot document Title: introduce line carrying slash Now we can use multiline commands with lines ending by configuring continuation symbol. Works only when there is no set delimiter. There is also an alias `\set c on|off`, that does the same. Consider the example where the marker is set, used and removed: ``` tarantool> \set continuation on --- - true ... tarantool> a = 10\ > + 12 --- ... tarantool> \set c off --- - true ... tarantool> a = 10\ --- - error: '[string "a = 10\"]:1: unexpected symbol near ''\''' ... tarantool> ```
Lord-KA
added a commit
to Lord-KA/tarantool
that referenced
this issue
Feb 28, 2023
Language in `local_read()` used to be set to `box.session.language` while the latter is always `nil` and `set_language()` sets `self.language`. Now the language in `local_read()` is identified correctly. Needed for tarantool#4317 NO_DOC=bugfix NO_CHANGELOG=invisible to user NO_TEST=invisible to user
Lord-KA
added a commit
to Lord-KA/tarantool
that referenced
this issue
Feb 28, 2023
GNU Readline starting from version 8.1 has bracketed paste[0] enabled by default which complicates handling pasted multiline text and is not supported for now. This patch disables the feature even if it is enabled in inputrc, by user or by default. [0] https://cirw.in/blog/bracketed-paste Needed for tarantool#4317 NO_TEST=readline config NO_DOC=readline config NO_CHANGELOG=readline config
Lord-KA
added a commit
to Lord-KA/tarantool
that referenced
this issue
Feb 28, 2023
Continuation marker can be set up with `\set continuation` command. Works on both server and client side in any language. Closes tarantool#4317 Requires tarantool#7357 @TarantoolBot document Title: introduce line carrying slash Now we can use multiline commands with lines ending by configuring continuation symbol. Works only when there is no set delimiter. There is also an alias `\set c on|off`, that does the same. Consider the example where the marker is set, used and removed: ``` tarantool> \set continuation on --- - true ... tarantool> a = 10\ > + 12 --- ... tarantool> \set c off --- - true ... tarantool> a = 10\ --- - error: '[string "a = 10\"]:1: unexpected symbol near ''\''' ... tarantool> ```
Lord-KA
added a commit
to Lord-KA/tarantool
that referenced
this issue
Feb 28, 2023
Continuation marker can be set up with `\set continuation` command. Works on both server and client side in any language. Closes tarantool#4317 Requires tarantool#7357 @TarantoolBot document Title: introduce line carrying slash Now we can use multiline commands with lines ending by configuring continuation symbol. Works only when there is no set delimiter. There is also an alias `\set c on|off`, that does the same. Consider the example where the marker is set, used and removed: ``` tarantool> \set continuation on --- - true ... tarantool> a = 10\ > + 12 --- ... tarantool> \set c off --- - true ... tarantool> a = 10\ --- - error: '[string "a = 10\"]:1: unexpected symbol near ''\''' ... tarantool> ```
Lord-KA
added a commit
to Lord-KA/tarantool
that referenced
this issue
Feb 28, 2023
GNU Readline starting from version 8.1 has bracketed paste[0] enabled by default which complicates handling pasted multiline text and is not supported for now. This patch disables the feature even if it is enabled in inputrc, by user or by default. [0] https://cirw.in/blog/bracketed-paste Needed for tarantool#4317 NO_TEST=readline config NO_DOC=readline config NO_CHANGELOG=readline config
Lord-KA
added a commit
to Lord-KA/tarantool
that referenced
this issue
Feb 28, 2023
Language in `local_read()` used to be set to `box.session.language` while the latter is always `nil` and `set_language()` sets `self.language`. Now the language in `local_read()` is identified correctly. Needed for tarantool#4317 NO_DOC=bugfix NO_CHANGELOG=invisible to user NO_TEST=invisible to user
Lord-KA
added a commit
to Lord-KA/tarantool
that referenced
this issue
Feb 28, 2023
Continuation marker can be set up with `\set continuation` command. Works on both server and client side in any language. Closes tarantool#4317 Requires tarantool#7357 @TarantoolBot document Title: introduce line carrying slash Now we can use multiline commands with lines ending by configuring continuation symbol. Works only when there is no set delimiter. There is also an alias `\set c on|off`, that does the same. Consider the example where the marker is set, used and removed: ``` tarantool> \set continuation on --- - true ... tarantool> a = 10\ > + 12 --- ... tarantool> \set c off --- - true ... tarantool> a = 10\ --- - error: '[string "a = 10\"]:1: unexpected symbol near ''\''' ... tarantool> ```
Lord-KA
added a commit
to Lord-KA/tarantool
that referenced
this issue
Feb 28, 2023
Continuation marker can be set up with `\set continuation` command. Works on both server and client side in any language. Closes tarantool#4317 Requires tarantool#7357 @TarantoolBot document Title: introduce line carrying slash Now we can use multiline commands with lines ending by configuring continuation symbol. Works only when there is no set delimiter. There is also an alias `\set c on|off`, that does the same. Consider the example where the marker is set, used and removed: ``` tarantool> \set continuation on --- - true ... tarantool> a = 10\ > + 12 --- ... tarantool> \set continuation off --- - true ... tarantool> a = 10\ --- - error: '[string "a = 10\"]:1: unexpected symbol near ''\''' ... tarantool> ```
Lord-KA
added a commit
to Lord-KA/tarantool
that referenced
this issue
Feb 28, 2023
Continuation marker can be set up with `\set continuation` command. Works on both server and client side in any language. Closes tarantool#4317 Requires tarantool#7357 @TarantoolBot document Title: introduce line carrying slash Now we can use multiline commands with lines ending by configuring continuation symbol. Works only when there is no set delimiter. There is also an alias `\set c on|off`, that does the same. Consider the example where the marker is set, used and removed: ``` tarantool> \set continuation on --- - true ... tarantool> a = 10\ > + 12 --- ... tarantool> \set continuation off --- - true ... tarantool> a = 10\ --- - error: '[string "a = 10\"]:1: unexpected symbol near ''\''' ... tarantool> ```
Lord-KA
added a commit
to Lord-KA/tarantool
that referenced
this issue
Mar 6, 2023
Language in `local_read()` used to be set to `box.session.language` while the latter is always `nil` and `set_language()` sets `self.language`. Now the language in `local_read()` is identified correctly. This is required for performing continuation check (tarantoolgh-4317) only in Lua mode. Needed for tarantool#4317 NO_DOC=refactoring NO_CHANGELOG=refactoring NO_TEST=invisible to user
Lord-KA
added a commit
to Lord-KA/tarantool
that referenced
this issue
Mar 6, 2023
Continuation marker can be set up with `\set continuation` command. Works on both server and client side in any language. Closes tarantool#4317 Requires tarantool#7357 @TarantoolBot document Title: introduce line carrying slash Now we can use multiline commands with lines ending by configuring continuation symbol. Works only when there is no set delimiter. There is also an alias `\set c on|off`, that does the same. Consider the example where the marker is set, used and removed: ``` tarantool> \set continuation on --- - true ... tarantool> a = 10\ > + 12 --- ... tarantool> \set continuation off --- - true ... tarantool> a = 10\ --- - error: '[string "a = 10\"]:1: unexpected symbol near ''\''' ... tarantool> ```
Lord-KA
added a commit
to Lord-KA/tarantool
that referenced
this issue
Mar 6, 2023
Language in `local_read()` used to be set to `box.session.language` while the latter is always `nil` and `set_language()` sets `self.language`. Now the language in `local_read()` is identified correctly. This is required for performing continuation check (tarantoolgh-4317) on any language while the check for complete lua statement happens only in Lua mode. Needed for tarantool#4317 NO_DOC=refactoring NO_CHANGELOG=refactoring NO_TEST=invisible to user
Lord-KA
added a commit
to Lord-KA/tarantool
that referenced
this issue
Mar 6, 2023
Continuation marker can be set up with `\set continuation` command. Works on both server and client side in any language. Closes tarantool#4317 Requires tarantool#7357 @TarantoolBot document Title: introduce line carrying slash Now we can use multiline commands with lines ending by configuring continuation symbol. Works only when there is no set delimiter. There is also an alias `\set c on|off`, that does the same. Consider the example where the marker is set, used and removed: ``` tarantool> \set continuation on --- - true ... tarantool> a = 10\ > + 12 --- ... tarantool> \set continuation off --- - true ... tarantool> a = 10\ --- - error: '[string "a = 10\"]:1: unexpected symbol near ''\''' ... tarantool> ```
Lord-KA
added a commit
to Lord-KA/tarantool
that referenced
this issue
Mar 6, 2023
Continuation marker can be set up with `\set continuation` command. Works on both server and client side in any language. Closes tarantool#4317 Requires tarantool#7357 @TarantoolBot document Title: introduce line carrying slash Now we can use multiline commands with lines ending by configuring continuation symbol. Works only when there is no set delimiter. There is also an alias `\set c on|off`, that does the same. Consider the example where the marker is set, used and removed: ``` tarantool> \set continuation on --- - true ... tarantool> a = 10\ > + 12 --- ... tarantool> \set continuation off --- - true ... tarantool> a = 10\ --- - error: '[string "a = 10\"]:1: unexpected symbol near ''\''' ... tarantool> ```
Lord-KA
added a commit
to Lord-KA/tarantool
that referenced
this issue
Mar 6, 2023
Continuation marker can be set up with `\set continuation` command. Works on both server and client side in any language. Closes tarantool#4317 Requires tarantool#7357 @TarantoolBot document Title: introduce line carrying slash Now we can use multiline commands with lines ending by configuring continuation symbol. Works only when there is no set delimiter. There is also an alias `\set c on|off`, that does the same. Consider the example where the marker is set, used and removed: ``` tarantool> \set continuation on --- - true ... tarantool> a = 10\ > + 12 --- ... tarantool> \set continuation off --- - true ... tarantool> a = 10\ --- - error: '[string "a = 10\"]:1: unexpected symbol near ''\''' ... tarantool> ```
Lord-KA
added a commit
to Lord-KA/tarantool
that referenced
this issue
Mar 6, 2023
Continuation marker can be set up with `\set continuation` command. Works on both server and client side in any language. Closes tarantool#4317 Requires tarantool#7357 @TarantoolBot document Title: introduce line carrying slash Now we can use multiline commands with lines ending by configuring continuation symbol. Works only when there is no set delimiter. There is also an alias `\set c on|off`, that does the same. Consider the example where the marker is set, used and removed: ``` tarantool> \set continuation on --- - true ... tarantool> a = 10\ > + 12 --- ... tarantool> \set continuation off --- - true ... tarantool> a = 10\ --- - error: '[string "a = 10\"]:1: unexpected symbol near ''\''' ... tarantool> ```
Lord-KA
added a commit
to Lord-KA/tarantool
that referenced
this issue
Mar 7, 2023
Continuation marker can be set up with `\set continuation` command. Works on both server and client side in any language. Closes tarantool#4317 Requires tarantool#7357 @TarantoolBot document Title: introduce line carrying slash Now we can use multiline commands with lines ending by configuring continuation symbol. Works only when there is no set delimiter. Consider the example where the marker is set, used and removed: ``` tarantool> \set continuation on --- - true ... tarantool> a = 10\ > + 12 --- ... tarantool> \set continuation off --- - true ... tarantool> a = 10\ --- - error: '[string "a = 10\"]:1: unexpected symbol near ''\''' ... tarantool> ```
Lord-KA
added a commit
to Lord-KA/tarantool
that referenced
this issue
Mar 7, 2023
Continuation marker can be set up with `\set continuation` command. Works on both server and client side in any language. Closes tarantool#4317 Requires tarantool#7357 @TarantoolBot document Title: introduce line carrying slash Now we can use multiline commands with lines ending by configuring continuation symbol. Works only when there is no set delimiter. Consider the example where the marker is set, used and removed: ``` tarantool> \set continuation on --- - true ... tarantool> a = 10\ > + 12 --- ... tarantool> \set continuation off --- - true ... tarantool> a = 10\ --- - error: '[string "a = 10\"]:1: unexpected symbol near ''\''' ... tarantool> ```
Lord-KA
added a commit
to Lord-KA/tarantool
that referenced
this issue
Mar 7, 2023
Continuation marker can be set up with `\set continuation` command. Works on both server and client side in any language. Closes tarantool#4317 Requires tarantool#7357 @TarantoolBot document Title: introduce line carrying slash Now we can use multiline commands with lines ending by configuring continuation symbol. Works only when there is no set delimiter. Consider the example where the marker is set, used and removed: ``` tarantool> \set continuation on --- - true ... tarantool> a = 10\ > + 12 --- ... tarantool> \set continuation off --- - true ... tarantool> a = 10\ --- - error: '[string "a = 10\"]:1: unexpected symbol near ''\''' ... tarantool> ```
Lord-KA
added a commit
to Lord-KA/tarantool
that referenced
this issue
Mar 7, 2023
Continuation marker can be set up with `\set continuation` command. Works on both server and client side in any language. Closes tarantool#4317 Requires tarantool#7357 @TarantoolBot document Title: introduce line carrying slash Now we can use multiline commands with lines ending by configuring continuation symbol. Works only when there is no set delimiter. Consider the example where the marker is set, used and removed: ``` tarantool> \set continuation on --- - true ... tarantool> a = 10\ > + 12 --- ... tarantool> \set continuation off --- - true ... tarantool> a = 10\ --- - error: '[string "a = 10\"]:1: unexpected symbol near ''\''' ... tarantool> ```
igormunkin
pushed a commit
that referenced
this issue
Mar 9, 2023
GNU Readline starting from version 8.1 has bracketed paste[0] enabled by default which complicates handling pasted multiline text and is not supported for now. This patch disables the feature even if it is enabled in inputrc, by user or by default. [0] https://cirw.in/blog/bracketed-paste Needed for #4317 NO_TEST=readline config NO_DOC=readline config NO_CHANGELOG=readline config
igormunkin
pushed a commit
that referenced
this issue
Mar 9, 2023
Language in `local_read()` used to be set to `box.session.language` while the latter is always `nil` and `set_language()` sets `self.language`. Now the language in `local_read()` is identified correctly. This is required for performing continuation check (gh-4317) on any language while the check for complete lua statement happens only in Lua mode. Needed for #4317 NO_DOC=refactoring NO_CHANGELOG=refactoring NO_TEST=invisible to user
nshy
added a commit
to nshy/tarantool
that referenced
this issue
Mar 30, 2023
Currently test can fail if in developer environment .inputrc is custom. Follow-up tarantool#4317 NO_TEST=test fix NO_DOC=test fix NO_CHANGELOG=test fix
nshy
added a commit
to nshy/tarantool
that referenced
this issue
Mar 30, 2023
Currently test can fail if in developer environment .inputrc is custom. Follow-up tarantool#4317 NO_TEST=test fix NO_DOC=test fix NO_CHANGELOG=test fix
locker
pushed a commit
that referenced
this issue
Mar 31, 2023
Currently test can fail if in developer environment .inputrc is custom. Follow-up #4317 NO_TEST=test fix NO_DOC=test fix NO_CHANGELOG=test fix
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
It is often more convenient to split a long command then set a delimiter before and unset it after.
We have auto-guessing for Lua whether a command ends on a current line (however there are cases where it is hard to determine, see #4082), so this feature is more useful for SQL, where we have no such guessing.
The primary reason is to support copy-paste from a source where long line are discouraged: a test file or an example from documentation.
The backslash character should have the special meaning only when it is at end of a line.
The text was updated successfully, but these errors were encountered: