{"id":13459938,"url":"https://github.com/MichaelMure/go-term-markdown","last_synced_at":"2025-03-24T18:31:36.460Z","repository":{"id":36795634,"uuid":"197447315","full_name":"MichaelMure/go-term-markdown","owner":"MichaelMure","description":"A markdown renderer package for the terminal","archived":false,"fork":false,"pushed_at":"2023-06-22T02:17:27.000Z","size":2125,"stargazers_count":273,"open_issues_count":23,"forks_count":33,"subscribers_count":6,"default_branch":"master","last_synced_at":"2024-10-22T22:52:27.709Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/MichaelMure.png","metadata":{"files":{"readme":"Readme.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null},"funding":{"open_collective":"git-bug"}},"created_at":"2019-07-17T19:06:53.000Z","updated_at":"2024-10-17T11:51:41.000Z","dependencies_parsed_at":"2024-01-18T03:47:21.783Z","dependency_job_id":null,"html_url":"https://github.com/MichaelMure/go-term-markdown","commit_stats":{"total_commits":69,"total_committers":5,"mean_commits":13.8,"dds":"0.34782608695652173","last_synced_commit":"d84f2b9b34f9b8beadd9307bff0592620f7b9578"},"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MichaelMure%2Fgo-term-markdown","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MichaelMure%2Fgo-term-markdown/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MichaelMure%2Fgo-term-markdown/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MichaelMure%2Fgo-term-markdown/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/MichaelMure","download_url":"https://codeload.github.com/MichaelMure/go-term-markdown/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":221995810,"owners_count":16913565,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-07-31T10:00:32.641Z","updated_at":"2024-10-29T05:31:24.141Z","avatar_url":"https://github.com/MichaelMure.png","language":"Go","funding_links":["https://opencollective.com/git-bug"],"categories":["Misc","语言资源库","Go"],"sub_categories":["go"],"readme":"# go-term-markdown\n\n[![Build Status](https://travis-ci.com/MichaelMure/go-term-markdown.svg?branch=master)](https://travis-ci.com/MichaelMure/go-term-markdown)\n[![GoDoc](https://godoc.org/github.com/MichaelMure/go-term-markdown?status.svg)](https://godoc.org/github.com/MichaelMure/go-term-markdown)\n[![Go Report Card](https://goreportcard.com/badge/github.com/MichaelMure/go-term-markdown)](https://goreportcard.com/report/github.com/MichaelMure/go-term-markdown)\n[![codecov](https://codecov.io/gh/MichaelMure/go-term-markdown/branch/master/graph/badge.svg)](https://codecov.io/gh/MichaelMure/go-term-markdown)\n[![GitHub license](https://img.shields.io/github/license/MichaelMure/go-term-markdown.svg)](https://github.com/MichaelMure/go-term-markdown/blob/master/LICENSE)\n[![Gitter chat](https://badges.gitter.im/gitterHQ/gitter.png)](https://gitter.im/the-git-bug/Lobby)\n\n`go-term-markdown` is a go package implementing a Markdown renderer for the terminal.\n\nNote: Markdown being originally designed to render as HTML, rendering in a terminal is occasionally challenging and some adaptation had to be made. \n\nFeatures:\n- formatting\n- lists\n- tables\n- images\n- code blocks with syntax highlighting\n- basic HTML support\n\nNote: this renderer is packaged as a standalone terminal viewer at https://github.com/MichaelMure/mdr/\n\n## Usage\n\n```go\nimport (\n\t\"fmt\"\n\t\"io/ioutil\"\n\n\tmarkdown \"github.com/MichaelMure/go-term-markdown\"\n)\n\nfunc main() {\n\tpath := \"Readme.md\"\n\tsource, err := ioutil.ReadFile(path)\n\tif err != nil {\n\t\tpanic(err)\n\t}\n\n\tresult := markdown.Render(string(source), 80, 6)\n\n\tfmt.Println(result)\n}\n```\n\n## Example\n\nHere is the [Readme](https://github.com/MichaelMure/go-term-text/blob/v0.2.4/Readme.md) of `go-term-text` rendered with `go-term-markdown`:\n\n![rendering example](misc/result.png)\n\nHere is an example of table rendering:\n\n![table rendering](misc/table.png)\n\n## Origin\n\nThis package has been extracted from the [git-bug](https://github.com/MichaelMure/git-bug) project. As such, its aim is to support this project and not to provide an all-in-one solution. Contributions or full-on takeover as welcome though.\n\n## Contribute\n\nPRs accepted.\n\n## License\n\nMIT\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FMichaelMure%2Fgo-term-markdown","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FMichaelMure%2Fgo-term-markdown","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FMichaelMure%2Fgo-term-markdown/lists"}