mirror of
https://github.com/matrix-construct/construct
synced 2024-11-26 08:42:34 +01:00
modules/console: Add state indicator on room gaps output.
modules/console: Minor cleanup fetch cmd section.
This commit is contained in:
parent
4a37152c6d
commit
d4510acf9c
1 changed files with 26 additions and 21 deletions
|
@ -7901,6 +7901,8 @@ console_cmd__room__depth__gaps(opt &out, const string_view &line)
|
||||||
<< " -> "
|
<< " -> "
|
||||||
<< std::left << std::setw(8) << range.second
|
<< std::left << std::setw(8) << range.second
|
||||||
<< " "
|
<< " "
|
||||||
|
<< (m::room::state::is(std::nothrow, event_idx)? "S" : " ")
|
||||||
|
<< " "
|
||||||
<< m::event_id(event_idx)
|
<< m::event_id(event_idx)
|
||||||
<< std::endl;
|
<< std::endl;
|
||||||
|
|
||||||
|
@ -13335,27 +13337,7 @@ console_cmd__mc__register__available(opt &out, const string_view &line)
|
||||||
//
|
//
|
||||||
|
|
||||||
bool
|
bool
|
||||||
console_cmd__fetch__list(opt &out, const string_view &line)
|
console_cmd__fetch__list(opt &out, const string_view &line);
|
||||||
{
|
|
||||||
m::fetch::for_each([&out]
|
|
||||||
(const m::fetch::request &request)
|
|
||||||
{
|
|
||||||
out
|
|
||||||
<< std::left << std::setw(64) << trunc(request.event_id, 64) << " "
|
|
||||||
<< std::left << std::setw(40) << trunc(request.room_id, 40) << " "
|
|
||||||
<< std::left << std::setw(32) << trunc(request.origin, 32) << " "
|
|
||||||
<< std::left << "S:" << request.started << " "
|
|
||||||
<< std::left << "A:" << request.attempted.size() << " "
|
|
||||||
<< std::left << "E:" << bool(request.eptr) << " "
|
|
||||||
<< std::left << "F:" << request.finished << " "
|
|
||||||
<< std::endl
|
|
||||||
;
|
|
||||||
|
|
||||||
return true;
|
|
||||||
});
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
bool
|
bool
|
||||||
console_cmd__fetch(opt &out, const string_view &line)
|
console_cmd__fetch(opt &out, const string_view &line)
|
||||||
|
@ -13388,6 +13370,29 @@ console_cmd__fetch(opt &out, const string_view &line)
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
bool
|
||||||
|
console_cmd__fetch__list(opt &out, const string_view &line)
|
||||||
|
{
|
||||||
|
m::fetch::for_each([&out]
|
||||||
|
(const m::fetch::request &request)
|
||||||
|
{
|
||||||
|
out
|
||||||
|
<< std::left << std::setw(64) << trunc(request.event_id, 64) << " "
|
||||||
|
<< std::left << std::setw(40) << trunc(request.room_id, 40) << " "
|
||||||
|
<< std::left << std::setw(32) << trunc(request.origin, 32) << " "
|
||||||
|
<< std::left << "S:" << request.started << " "
|
||||||
|
<< std::left << "A:" << request.attempted.size() << " "
|
||||||
|
<< std::left << "E:" << bool(request.eptr) << " "
|
||||||
|
<< std::left << "F:" << request.finished << " "
|
||||||
|
<< std::endl
|
||||||
|
;
|
||||||
|
|
||||||
|
return true;
|
||||||
|
});
|
||||||
|
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
bool
|
bool
|
||||||
console_cmd__fetch__clear(opt &out, const string_view &line)
|
console_cmd__fetch__clear(opt &out, const string_view &line)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue