Remove mdcat dependency (#2959)

This commit is contained in:
Charlie Marsh 2023-02-16 12:09:37 -05:00 committed by GitHub
parent fdcb78fd8c
commit 370c3a5daf
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 6 additions and 850 deletions

View file

@ -63,24 +63,6 @@ pub fn linter(format: HelpFormat) -> Result<()> {
output.push_str(&serde_json::to_string_pretty(&linters)?);
output.push('\n');
}
HelpFormat::Pretty => {
output.push_str(&format!("| {:>6} | {:<27} |\n", "Prefix", "Name"));
output.push_str(&format!("| {:>6} | {:<27} |\n", "------", "-".repeat(27)));
for linter in Linter::iter() {
let prefix = match linter.common_prefix() {
"" => linter
.upstream_categories()
.unwrap()
.iter()
.map(|UpstreamCategory(prefix, ..)| prefix.short_code())
.join("/"),
prefix => prefix.to_string(),
};
output.push_str(&format!("| {:>6} | {:<27} |\n", prefix, linter.name()));
}
}
}
write!(stdout, "{output}")?;