shithub: hell

Download patch

ref: 566d628e2c8e1a34fc4ab72a6c6a3be41071460b
parent: bb3fc3cf35f13e124b836061f39db148c899d5ed
author: penny <penny@limitedideas.org>
date: Tue Oct 28 18:11:51 EDT 2025

render account profiles with unix line breaks

--- a/mastodon.go
+++ b/mastodon.go
@@ -161,7 +161,7 @@
 	sb.WriteString(fmt.Sprintf("Posts: %v Followers: %v Following: %v\n", account.StatusesCount, account.FollowersCount, account.FollowingCount))
 	sb.WriteString(fmt.Sprintf("Created %v\n", account.CreatedAt))
 	sb.WriteString(fmt.Sprintf("Locked: %v\n", account.Locked))
-	sb.WriteString(fmt.Sprintf("%s\n\n", html2text.HTML2Text(account.Note)))
+	sb.WriteString(fmt.Sprintf("%s\n\n", html2text.HTML2TextWithOptions(account.Note, html2text.WithUnixLineBreaks(), html2text.WithListSupport())))
 
 	relationships, err := hc.client.GetAccountRelationships(context.Background(), []string{string(account.ID)})
 	relationship := relationships[0]
--