aboutsummaryrefslogtreecommitdiff
path: root/src/shell.c.in
AgeCommit message (Collapse)AuthorLines
4 daysImprovements to "json" mode in QRF.HEADlocal/sqlitemasterdrh-1/+7
[bugs:/info/2026-11-22T07:30:35Z|Bug 2026-11-22T07:30:35Z] FossilOrigin-Name: ac22af8bd58cb1f6190438cae90f607fe10b96094526b855cafeb84f8855ce05
5 daysSlightly simplify how the shell's --quote flag handling is done to address ↵stephan-21/+18
[bugs:68e212780c|bug report 2026-11-21T02:47:14Z]. New test cases. FossilOrigin-Name: 3b86db209d9c5991cf1f1ac36f153ee70745369d9758be3b338e94749b5a142e
5 daysFix an early return out of a va_start/va_end block in the shell's pickStr().stephan-1/+2
FossilOrigin-Name: 64f067d52976ce85fd2d2eae0bf5650af859bc2e8e81a8ba7927adf9168c77ca
5 daysProperly escape the content of the sqlite_statN tables when doing .fullschemadrh-0/+1
in the CLI. [bugs:/info/2026-11-21T01:05:21Z|Bug 2026-11-21T01:05:21Z] FossilOrigin-Name: f33b248fcea770dd8870959973b33c0da178c5e97f3cca03b33a439aea18e9cf
6 daysAs demonstrated by multiple bug reports, the SQLITE_DBCONFIG_FP_DIGITSdrh-1/+22
setting from [3f16985dcc47a366] is unsafe if misused, and so it is here changed into a no-op. FossilOrigin-Name: 5b588b3e0ff81920514098dd98307cf64c37cef17c30df028e344cc0b8b0a267
6 daysAdd the -v option to the CLI, which if present causes each successful .checkdrh-0/+10
command to display its identify with "ok" on standard output. FossilOrigin-Name: b36768c4676b5163652c1944ffa7a6a6d398e3003604734e28b10a0fb7c11709
6 daysFix the URI parsing built into the CLI so that it does the same thing withdrh-8/+4
%-escapes as the SQLite core does. [bugs:/info/2026-11-20T03:13:17Z|Bug 2026-11-20T03:13:17Z] FossilOrigin-Name: 102d7b9adb21f8c079993e0d5b76f2d208e074c2a4322dda7682e18b634bf4d1
6 daysEnhance both the CLI and the ext/misc/dbdump.c library so that it is moredrh-6/+76
rebust against injection attacks. Inspired by [bugs:/info/2026-11-19T15:45:09Z|bug report 2026-11-19T15:45:09Z] but going well beyond that report. FossilOrigin-Name: 1e84c333e8ea12770d1c377371d8538c753f8f51e9a2570b670e165eec1d76dd
7 daysCLI shell: Fix a NULL deref in .read heredoc parsing which could happen on ↵stephan-2/+7
OOM or an empty heredoc. Add an empty-heredoc test. FossilOrigin-Name: edcd4c4667ae4f654b147525c7282b7d9112e9509f649a7d5cf70650bd429e37
7 daysCLI shell: do not impose the db-configured size limits for error messages ↵stephan-3/+3
unrelated to the current db connection. Add tests ensuring that that truncation doesn't happen to the affected messages. FossilOrigin-Name: 4b68e72715d2fce4bb74318b70adfcd85296af73f4681403e9c17b477fd63810
7 daysImproved parsing of options to the .recover command of the CLI.drh-9/+15
[bugs:/info/2026-11-18T16:10:01Z|Bug 2026-11-18T16:10:01Z] FossilOrigin-Name: acc4a0c499c66e08c98e24c8945d619ec255f83d95793651489e098dd4f2f664
9 daysCLI shell: disable sqlite3_completion_init() in fiddle builds, where it's ↵stephan-0/+2
unavailable. FossilOrigin-Name: fa9964fe4f050c6c3c6acb50f1c46a6104aa0b6aee5aed90d3ab83ac8abc7b46
9 daysRestore tab-completion in the CLI, accidentally deleted by [d58866448b23b996].drh-0/+1
[bugs:/info/2026-11-16T23:43:44Z|Bug 2026-11-16T23:43:44Z]. FossilOrigin-Name: f8c1113c378bcd4c2fb5d1ddd5a23882fb8aa55238707a141f2856e093d29e6d
10 daysEnhancements to the ".testctrl tune" dot-command in the CLI.drh-4/+2
FossilOrigin-Name: 447a681116cc5e2650a884322f0a8e6efa620c5b13aaa8cf0d4655357e726545
11 daysEnhance the .check command of the CLI so that the PATTERN is thedrh-21/+24
concatenation with space separator of all non-option arguments. Also fix a bug that prevented the CLI from compiling with SQLITE_OMIT_LOAD_EXTENSION. FossilOrigin-Name: cf2c3c8f122d56a07b2de793cbc670580e079cf22b935e601025e8aeca61bff6
11 daysInclude the tryeval extension in the CLI, but disable it in safe mode.drh-7/+10
Also disable extension loading in safe mode, as an added safety. FossilOrigin-Name: d58866448b23b996473088b642b14aed17319b3c5a28a0c6aa0441d1f9fd2370
11 daysExtend the capable(X) function again with capable('unsafe') which is truedrh-4/+12
as long as the CLI was not launched with --safe and the .safe command has not been run. FossilOrigin-Name: 7f9fec67240df4555a4c699f34162b9f36337b98e8c649bfbc371eaa36a8b897
12 daysEnhance the capable(X) function in the CLI so that it also looks atdrh-8/+25
available VFSes. So now you can do ".if capable('unix')" or similar in script. FossilOrigin-Name: dad81fcfd6fb42a9cb85ea5757452e45620b715b50321745ed8d5210e50b8651
12 daysFix recent test cases so that they run on all configurations. Fix a verydrh-2/+5
minor memory leak in the CLI. FossilOrigin-Name: 6911bdb236d98cf3ed5b430d3c85cd7a085617f9c6f8457f2986d172baa1fe70
13 daysIn the CLI, ".open --deserialize" with no arguments should open andrh-1/+1
empty in-memory database and not call fopen() with a NULL filename. [bugs:/info/2026-11-13T12:52:21Z|bug 2026-11-13T12:52:21Z]. FossilOrigin-Name: 83388772bdfd72506141095f23f7bbf99b765cd491c0fa694479a6017c430779
2026-11-12Do not misidentify dot-commands as database files on the command-line parsingdrh-2/+6
of the CLI. Also fix a help typo. FossilOrigin-Name: 3c48444aff12f6801d055bcc1255f43b3150a27aa766b0deacb7cb789c803f4a
2026-11-11Fix bugs in and improve the interface to the ".check" command of the CLI.drh-50/+109
FossilOrigin-Name: 1a00748caf475548fb55d0362676746ad52c4dc58839dc78b412174000424522
2026-11-11Take out ".mode test" added as part of [85e50de017d28abc] since it is reallydrh-1/+0
just an alias for ".mode quote". Update recent test cases to use "quote" instead of "test". FossilOrigin-Name: 509c3506542a77d628dbab8b6ba5f7189b4712fcd8365b0b7873b875fc7ffd2a
2026-11-11Still more hardening against smuggled shell command attacks.drh-5/+36
FossilOrigin-Name: 8981033053d69c0a965525389971f6e5c248706d99eb14f32b386ece59d46fc5
2026-11-11Further strengthening of the new ".safe" command in the CLI.drh-4/+18
FossilOrigin-Name: d486e997908bbd1b5a323adae01db2de71b473b8ab5a792812ccd27bf5ae60ce
2026-11-11Add the ".safe" command to the CLI and enhance the ".recover" command sodrh-1/+49
that the script it generates includes the ".safe" command near the top. Prior check-in [d684ccc9ec4e41d8] is sufficient to block the attack described by [bugs:/info/2026-11-06T04:16:54Z|bug 2026-11-06T04:16:54Z] and [https://app.opencve.io/cve/CVE-2026-119586|CVE-2026-119586]. This check-in simply adds an additional layer of defense. FossilOrigin-Name: f2be7c2a98f2dc65dc03e1023da44f06d50860f8ec397e3616d76b15aa2fc646
2026-11-10In the CLI and the ".mode" command, clamp various parameters at the limitdrh-7/+22
of their range and do not allow integer truncation, as robots seem to not like integer truncation behavior in user interfaces. [bugs:/info/2026-11-05T22:26:14Z|Bug 2026-11-05T22:26:14Z] FossilOrigin-Name: a6250888ec8cd92b4459822e35a4bbd4ba025a9877efc917b35ee0cc944b7322
2026-11-10Fix NULL outputs for the "html" output mode in the CLI.drh-2/+2
[bugs:/info/2026-11-05T22:27:46Z|Bug 2026-11-05T22:27:46Z] FossilOrigin-Name: f827be82eadedcf314d894e6fae23645cda7cd2ac6109dc9d79502004432519b
2026-11-09More commentary on the operation of the capable() function that is builtdrh-0/+28
into the CLI. FossilOrigin-Name: 7d156a5fd301ac45fb23b5aa3cffe42fa0406819d22ced1162948d8488374f27
2026-11-08On Windows, provide globbing of scripts names to arguments of --runtests.drh-2/+57
FossilOrigin-Name: b90856289c715f05716ffd15c4304a6574cc2be7919aa3521018bab80a591852
2026-11-08Get the --runtests feature of the CLI working on Windows. Also fix severaldrh-12/+24
bugs introduced over the previous few CLI check-ins. FossilOrigin-Name: fcef53baca0dbdea862727f48331945cfb0b0fe307e7e9d0f70e2c4bb9dccd35
2026-11-08Add the --runtests option to the CLI.drh-2/+91
FossilOrigin-Name: 7e4d87f9a6aaaa4b0e63ffa2e32db1b351736560a5c87a84735f0087557fa5aa
2026-11-08Rename CLI tests that require special options from *.sql to *.clitest.drh-0/+1
Adjust all remaining *.sql tests so that they can all be run together using "sqlite3 test/*.sql". FossilOrigin-Name: 5b9cef877bd8255974276723a79b0e02c6d8b3ec35def545c07843c0f3be9f56
2026-11-08Improvements to the CLI to improve testing ability.drh-47/+97
(1) Add the "test" output mode that works like "list" but uses "," as the column separator and has "-quote on". (2) Add "--any", "--not", and "--regexp" to the ".check" command. (3) Default match algorithm for ".check" treats all whitespace characters as equal to one another. FossilOrigin-Name: 85e50de017d28abc98890714528611d717c4b369e8a4a7128a5c27b07ff80878
2026-11-07In the implementation of the CLI, break out the ".eqp" command intodrh-24/+96
a separate dotCmdEqp() function so that it can have better help text. And add the ability to redirect output to a file. FossilOrigin-Name: 707fc799ad235d4abe6445b6c0c147d6eb96e71a741a85a1b96a1f9702c94fc8
2026-11-06Fix a harmless compiler warning in the CLI.drh-0/+1
FossilOrigin-Name: 3eb5d986276fc4c16afd97ceb8ce66907c9bf76ca7893b54027b6796d3a33563
2026-11-05Add the custom SQL function "dualrep(X)" to the CLI. This function returnsdrh-0/+20
its argument X. If the argument is numeric, it returns an sqlite3_value object that contains both the numeric and the text representation. This is useful for testing. FossilOrigin-Name: 17f27736c56c4fe9c1154a4c5ed56788b1568ba3c309c2ad119b753510d2997f
2026-11-05Redact hostile column names from comments in the output of the ".lint"drh-0/+3
command of the CLI. [bugs:/info/2026-10-29T14:50:08Z|Bug 2026-10-29T14:50:08Z] FossilOrigin-Name: 0f19654cf20cc8428b80751e9b8c474d4cdff7b74d70fbbb1c58b7d0f7532a29
2026-11-05Use %lld to print a 64-bit quantity in the .import command of the CLI.drh-1/+1
[forum:/info/2026-11-05T14:36:54Z|Forum post 2026-11-05T14:36:54Z]. FossilOrigin-Name: 873591876f5fdf61ff55e81f680b9380312d0cfdfb2ba50f7b74fd560d6aba3b
2026-11-05The ".mode --reset" command in the CLI should not change the ".echo" mode.drh-2/+4
FossilOrigin-Name: 5caff0088874e1701b7d96d8d4b685eeaa6d753db0277df4baad0321d5568970
2026-11-04Fix .fullschema --indent being ignored. [bugs:c759843743|Bug report ↵stephan-2/+3
2026-11-04T20:35:51Z]. FossilOrigin-Name: ad609aa905a95e6f776bb042a2765fdde1790b3788662d8b1514d30441f41e83
2026-11-04When multiple *.sql files are specific on the CLI command-line, do not stopdrh-1/+1
if one of them fails, unless the --bail flag is used. This facilities running a whole batch of test scripts all in one command. FossilOrigin-Name: c28afd7acdd78dc9d051edb699e6fb3f7891a22f4aff72bc7460740fb265fe38
2026-11-04Add an int cast to a variadic argument in the shell. [bugs:eebb3e2ca7|bug ↵stephan-1/+1
report 2026-11-04T13:36:13Z]. FossilOrigin-Name: bcdafc082fa123ed2b07e024eef65076de20a7b412b7a5c5166b97a76e4fd12c
2026-11-04Use box-drawing characters to highlight the "Expected" and "Got" outputdrh-2/+25
from failed ".check" lines in the CLI, for improved debug support. FossilOrigin-Name: 7f29d38362e01eb16982de84c68c70492d737fb755e6a8cdf51063db0c2d9866
2026-11-03Shell: cast literal zeroes in int-pointer variadic arg slots to int-pointer ↵stephan-25/+31
for arg type compliance. [forum:e1f563c682|Forum post 2026-11-03T12:59:51Z]. FossilOrigin-Name: b0b3ca1ca903123a6c2fb8b2aefbbbb5c0bf975474ca1e0166703675629da18a
2026-11-03Always cast the second argument of SQLITE_CONFIG_LOG to (void*) to avoiddrh-1/+1
harmless UB warnings. [bugs:/info/2026-11-03T09:43:08Z|Bug 2026-11-03T09:43:08Z] FossilOrigin-Name: 7b0be56e725023da0bb065c89175949b4aba32e768e2a8d5ceaa006371aa8a51
2026-11-01Ensure that the database schema has been read prior to generating a hexdrh-0/+1
dump of a database file using ".dbtotxt" in the CLI. FossilOrigin-Name: 7bed0b36e45d76f83ba1351e9f09ac004b4409d8e49fe740a437c652457705fe
2026-10-31Fix the display of current optimizations in the CLI.drh-1/+1
FossilOrigin-Name: 8d891830ddd8923c3b2a316a688aad22d76fb6fb3cf088d5d9b5da4725b50f69
2026-10-31Expand the optimization disable mask from 32 to 64 bits. Add a newdrh-8/+6
bit to disable the having-to-where optimization, for testing purposes. FossilOrigin-Name: 89ea66267618dd0d2ac9a1aa56665c16e209a23e6eb66bc170cd8af6a16bfb86
2026-10-29In the CLI, do parameter binding before running the EXPLAIN specifieddrh-1/+2
by the ".eqp on" setting, not afterwards, as binding can change the bytecode. Also, if vdbe_trace is engaged, print a line for each parameter bound. FossilOrigin-Name: a63cb048d4825191963275b6ca6b82a63276f57fa30e870b22a599cedf104437