static char *argv_get_help(RCmd *cmd, RCmdDesc *cd, RCmdParsedArgs *a, size_t detail, bool use_color) {
	RCons *cons = r_cons_singleton ();
	const char *pal_help_color = use_color? cons->context->pal.help: "",
		   *pal_input_color = use_color? cons->context->pal.input: "",
		   *pal_label_color = use_color? cons->context->pal.label: "",
		   *pal_reset = use_color? cons->context->pal.reset: "";

	RStrBuf *sb = r_strbuf_new (NULL);

	fill_usage_strbuf (sb, cd, use_color);

	switch (detail) {
	case 1:
		return r_strbuf_drain (sb);
	case 2:
		if (cd->help->description) {
			r_strbuf_appendf (sb, "\n%s\n", cd->help->description);
		}
		if (cd->help->examples) {
			r_strbuf_appendf (sb, "\n%sExamples:%s\n", pal_label_color, pal_reset);
			const RCmdDescExample *it = cd->help->examples;
			while (it->example) {
				r_strbuf_appendf (sb, "| %s%s%s %s# %s%s\n", pal_input_color,
					it->example, pal_reset, pal_help_color, it->comment, pal_reset);
				it++;
			}
		}
		return r_strbuf_drain (sb);
	default:
		r_strbuf_free (sb);
		return NULL;
	}
}
static char *argv_get_help(RCmd *cmd, RCmdDesc *cd, RCmdParsedArgs *a, size_t detail, bool use_color) {
	RCons *cons = r_cons_singleton ();
	const char *pal_help_color = use_color? cons->context->pal.help: "",
		   *pal_input_color = use_color? cons->context->pal.input: "",
		   *pal_label_color = use_color? cons->context->pal.label: "",
		   *pal_reset = use_color? cons->context->pal.reset: "";

	RStrBuf *sb = r_strbuf_new (NULL);

	fill_usage_strbuf (sb, cd, use_color);

	switch (detail) {
	case 1:
		return r_strbuf_drain (sb);
	case 2:
		if (cd->help->description) {
			r_strbuf_appendf (sb, "\n%s\n", cd->help->description);
		}
		if (cd->help->examples) {
			r_strbuf_appendf (sb, "\n%sExamples:%s\n", pal_label_color, pal_reset);
			const RCmdDescExample *it = cd->help->examples;
			while (it->example) {
				r_strbuf_appendf (sb, "| %s%s%s %s# %s%s\n", pal_input_color,
					it->example, pal_reset, pal_help_color, it->comment, pal_reset);
				it++;
			}
		}
		return r_strbuf_drain (sb);
	default:
		r_strbuf_free (sb);
		return NULL;
	}
}