feat(history): nodb backlog — statusbar opt-in, /history off persistence, /privacy runtime switch, /correction fix #116

Manually merged
jabber.developer merged 4 commits from feat/no-db-backlog-114 into master 2026-05-16 15:34:25 +00:00
11 changed files with 98 additions and 107 deletions
Showing only changes of commit df5b39fa7c - Show all commits

View File

@@ -1147,8 +1147,6 @@ cmd_ac_init(void)
autocomplete_add(status_state_ac, "xa");
autocomplete_add(status_state_ac, "dnd");
autocomplete_add(logging_ac, "group");
autocomplete_add(privacy_ac, "logging");
autocomplete_add(privacy_ac, "os");

View File

@@ -1660,19 +1660,14 @@ static const struct cmd_t command_defs[] = {
},
{ CMD_PREAMBLE("/logging",
parse_args, 2, 3, &cons_logging_setting)
parse_args, 0, 3, NULL)
CMD_MAINFUNC(cmd_logging)
CMD_TAGS(
CMD_TAG_CHAT)
CMD_SYN(
"/logging group on|off")
"/logging")
jabber.developer marked this conversation as resolved Outdated

I suggest we remove this command as well

I suggest we remove this command as well
CMD_DESC(
"Configure groupchat (MUC) logging. "
"Regular chat logging is controlled by /history.")
CMD_ARGS(
{ "group on|off", "Enable/Disable groupchat (room) logging." })
CMD_EXAMPLES(
"/logging group off")
"Deprecated. Use '/history' instead.")
},
{ CMD_PREAMBLE("/states",

View File

@@ -6731,17 +6731,7 @@ cmd_privacy(ProfWin* window, const char* const command, gchar** args)
gboolean
cmd_logging(ProfWin* window, const char* const command, gchar** args)
{
if (args[0] == NULL) {
cons_logging_setting();
return TRUE;
}
if (g_strcmp0(args[0], "group") == 0 && args[1] != NULL) {
_cmd_set_boolean_preference(args[1], "Groupchat logging", PREF_GRLOG);
return TRUE;
}
cons_bad_cmd_usage(command);
cons_show("The '/logging' command is deprecated, use '/history' instead.");
return TRUE;
}

View File

@@ -1948,27 +1948,12 @@ cons_log_setting(void)
cons_show("Log level (/log level) : %s", level);
}
void
cons_logging_setting(void)
{
if (prefs_get_boolean(PREF_CHLOG))
cons_show("Chat logging (/logging chat) : ON");
else
cons_show("Chat logging (/logging chat) : OFF");
if (prefs_get_boolean(PREF_GRLOG))
cons_show("Groupchat logging (/logging group) : ON");
else
cons_show("Groupchat logging (/logging group) : OFF");
}
void
cons_show_log_prefs(void)
{
cons_show("Logging preferences:");
cons_show("");

refers to now-invalid command this method, as well as cons_show_log_prefs, need to be properly dealt with.

refers to now-invalid command this method, as well as `cons_show_log_prefs`, need to be properly dealt with.
cons_log_setting();
cons_logging_setting();
cons_alert(NULL);
}
@@ -2862,11 +2847,6 @@ cons_privacy_setting(void)
{
cons_show("Database logging : %s", prefs_get_string(PREF_DBLOG));
if (prefs_get_boolean(PREF_CHLOG)) {
cons_show("Chat logging (/logging chat) : ON");
} else {
cons_show("Chat logging (/logging chat) : OFF");
}
if (prefs_get_boolean(PREF_HISTORY)) {
cons_show("Chat history (/history) : ON");
} else {

View File

@@ -330,7 +330,6 @@ void cons_history_setting(void);
void cons_carbons_setting(void);
void cons_receipts_setting(void);
void cons_log_setting(void);
void cons_logging_setting(void);
void cons_autoaway_setting(void);
void cons_reconnect_setting(void);
void cons_autoping_setting(void);