0
0
Fork 0
mirror of https://github.com/matrix-construct/construct synced 2024-11-19 08:21:09 +01:00

modules/console: Add -a option to resource cmd; hide unused resources by default.

This commit is contained in:
Jason Volk 2019-02-21 13:38:43 -08:00
parent 7f9b06e2c3
commit d064b9492c

View file

@ -4639,7 +4639,7 @@ console_cmd__resource(opt &out, const string_view &line)
param["method"]
};
if(path && method)
if(path && method && path != "-a")
{
const auto &r
{
@ -4671,6 +4671,9 @@ console_cmd__resource(opt &out, const string_view &line)
{
assert(mp.second);
const auto &m{*mp.second};
if(path != "-a" && !m.stats->requests)
continue;
out << std::setw(56) << std::left << p.first
<< " "
<< std::setw(7) << mp.first