config: remove support for default.scrollback

This commit is contained in:
Daniel Eklöf 2020-12-08 19:52:28 +01:00
parent 7b16802972
commit 6ec63eae00
No known key found for this signature in database
GPG key ID: 5BBD4992C116573F
2 changed files with 1 additions and 22 deletions

View file

@ -100,6 +100,7 @@ means foot can be PGO:d in e.g. sandboxed build scripts. See
### Removed
* Support for loading configuration from `$XDG_CONFIG_HOME/footrc`.
* **scrollback** option from `foot.ini`.
### Fixed

View file

@ -583,28 +583,6 @@ parse_section_main(const char *key, const char *value, struct config *conf,
mbstowcs(conf->word_delimiters, value, chars + 1);
}
else if (strcmp(key, "scrollback") == 0) {
LOG_WARN("deprecated: %s:%d: [default]: scrollback: use 'scrollback.lines' instead'", path, lineno);
const char fmt[] = "%s:%d: \033[1mdefault.scrollback\033[21m, use \033[1mscrollback.lines\033[21m instead";
char *text = xasprintf(fmt, path, lineno);
struct user_notification deprecation = {
.kind = USER_NOTIFICATION_DEPRECATED,
.text = text,
};
tll_push_back(conf->notifications, deprecation);
unsigned long lines;
if (!str_to_ulong(value, 10, &lines)) {
LOG_AND_NOTIFY_ERR(
"%s:%d: [default]: scrollback: expected an integer, got '%s'",
path, lineno, value);
return false;
}
conf->scrollback.lines = lines;
}
else {
LOG_AND_NOTIFY_ERR("%s:%u: [default]: %s: invalid key", path, lineno, key);
return false;