mirror of
https://github.com/safedep/pmg.git
synced 2026-08-03 07:24:09 +02:00
Enhance pmg outputs by adding colors and removing markdown notions
This commit is contained in:
@@ -76,3 +76,13 @@ func IsInstallCommand(pkgManager, cmd string) bool {
|
||||
}
|
||||
return false
|
||||
}
|
||||
|
||||
func removeMarkdown(text string) string {
|
||||
// Remove bold asterisks
|
||||
text = strings.ReplaceAll(text, "**", "")
|
||||
// Remove italic asterisks
|
||||
text = strings.ReplaceAll(text, "*", "")
|
||||
// Remove backticks
|
||||
text = strings.ReplaceAll(text, "`", "")
|
||||
return text
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user