{"id":16299584,"url":"https://github.com/dcwatson/bbcode","last_synced_at":"2025-04-13T06:22:08.578Z","repository":{"id":3795318,"uuid":"4873894","full_name":"dcwatson/bbcode","owner":"dcwatson","description":"A pure python bbcode parser and formatter.","archived":false,"fork":false,"pushed_at":"2024-10-25T00:19:14.000Z","size":3724,"stargazers_count":69,"open_issues_count":3,"forks_count":17,"subscribers_count":7,"default_branch":"main","last_synced_at":"2025-04-04T05:06:10.440Z","etag":null,"topics":["bbcode","markup","python"],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-2-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/dcwatson.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"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,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2012-07-03T15:25:44.000Z","updated_at":"2024-10-25T00:19:12.000Z","dependencies_parsed_at":"2024-12-18T09:02:06.767Z","dependency_job_id":"e5843241-782a-4eb6-a946-1ac87bc9d1c8","html_url":"https://github.com/dcwatson/bbcode","commit_stats":{"total_commits":108,"total_committers":9,"mean_commits":12.0,"dds":"0.17592592592592593","last_synced_commit":"e0b05546615c174a01c091ec134a803983264b69"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dcwatson%2Fbbcode","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dcwatson%2Fbbcode/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dcwatson%2Fbbcode/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dcwatson%2Fbbcode/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dcwatson","download_url":"https://codeload.github.com/dcwatson/bbcode/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248665755,"owners_count":21142123,"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":["bbcode","markup","python"],"created_at":"2024-10-10T20:48:38.022Z","updated_at":"2025-04-13T06:22:08.557Z","avatar_url":"https://github.com/dcwatson.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"Overview\n========\n\n**Latest Package**\nhttp://pypi.python.org/pypi/bbcode\n\n**Source Code**\nhttps://github.com/dcwatson/bbcode\n\n**Documentation**\nhttps://dcwatson.github.io/bbcode/\n\n[![CI Status](https://github.com/dcwatson/bbcode/workflows/CI/badge.svg)](https://github.com/dcwatson/bbcode/actions)\n\n\nInstallation\n============\n\nThe easiest way to install the bbcode module is with pip, e.g.:\n\n    pip install bbcode\n\n\nRequirements\n============\n\nPython 3.9+\n\n\nBasic Usage\n===========\n\n```python\n# Using the default parser.\nimport bbcode\nhtml = bbcode.render_html(text)\n\n# Installing simple formatters.\nparser = bbcode.Parser()\nparser.add_simple_formatter('hr', '\u003chr /\u003e', standalone=True)\nparser.add_simple_formatter('sub', '\u003csub\u003e%(value)s\u003c/sub\u003e')\nparser.add_simple_formatter('sup', '\u003csup\u003e%(value)s\u003c/sup\u003e')\n\n# A custom render function.\ndef render_color(tag_name, value, options, parent, context):\n    return '\u003cspan style=\"color:%s;\"\u003e%s\u003c/span\u003e' % (tag_name, value)\n\n# Installing advanced formatters.\nfor color in ('red', 'blue', 'green', 'yellow', 'black', 'white'):\n    parser.add_formatter(color, render_color)\n\n# Calling format with context.\nhtml = parser.format(text, somevar='somevalue')\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdcwatson%2Fbbcode","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdcwatson%2Fbbcode","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdcwatson%2Fbbcode/lists"}