{"id":15168627,"url":"https://github.com/matiaslina/perl6-pygments","last_synced_at":"2026-02-04T02:40:33.711Z","repository":{"id":150316053,"uuid":"164360435","full_name":"matiaslina/perl6-pygments","owner":"matiaslina","description":"Perl 6 wrapper for python pygments library.","archived":false,"fork":false,"pushed_at":"2019-04-13T23:23:27.000Z","size":18,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-07-13T22:26:30.652Z","etag":null,"topics":["perl6","pygments","syntax-highlighting","wrapper"],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"artistic-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/matiaslina.png","metadata":{"files":{"readme":"README.md","changelog":"Changes","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":"2019-01-07T01:05:35.000Z","updated_at":"2020-01-16T23:12:53.000Z","dependencies_parsed_at":"2023-04-29T00:17:50.571Z","dependency_job_id":null,"html_url":"https://github.com/matiaslina/perl6-pygments","commit_stats":{"total_commits":6,"total_committers":1,"mean_commits":6.0,"dds":0.0,"last_synced_commit":"4c21236e12cf8a4eb71380438f3dc940d8afd958"},"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/matiaslina/perl6-pygments","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/matiaslina%2Fperl6-pygments","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/matiaslina%2Fperl6-pygments/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/matiaslina%2Fperl6-pygments/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/matiaslina%2Fperl6-pygments/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/matiaslina","download_url":"https://codeload.github.com/matiaslina/perl6-pygments/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/matiaslina%2Fperl6-pygments/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29065010,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-04T01:55:38.219Z","status":"online","status_checked_at":"2026-02-04T02:00:07.999Z","response_time":62,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["perl6","pygments","syntax-highlighting","wrapper"],"created_at":"2024-09-27T06:23:57.292Z","updated_at":"2026-02-04T02:40:33.695Z","avatar_url":"https://github.com/matiaslina.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"NAME\n====\n\nPygments - Wrapper to python pygments library.\n\nSYNOPSIS\n========\n\nPrinting some code with a terminal formatter.\n\n    use Pygments;\n\n    my $code = q:to/ENDCODE/;\n    grammar Parser {\n        rule  TOP  { I \u003clove\u003e \u003clang\u003e }\n        token love { '♥' | love }\n        token lang { \u003c Perl Rust Go Python Ruby \u003e }\n    }\n\n    say Parser.parse: 'I ♥ Perl';\n    # OUTPUT: ｢I ♥ Perl｣ love =\u003e ｢♥｣ lang =\u003e ｢Perl｣\n\n    say Parser.parse: 'I love Rust';\n    # OUTPUT: ｢I love Rust｣ love =\u003e ｢love｣ lang =\u003e ｢Rust｣\n    ENDCODE\n\n    # Output to terminal with line numbers.\n    Pygments.highlight(\n        $code, \"perl6\", :formatter\u003cterminal\u003e,\n        :linenos(True)\n    ).say;\n\nAlso it can be used with `Pod::To::HTML`:\n\n    use Pygments;\n\n    # Set the pod code callback to use pygments before *use* it\n    my %*POD2HTML-CALLBACKS;\n    %*POD2HTML-CALLBACKS\u003ccode\u003e = sub (:$node, :\u0026default) {\n        Pygments.highlight($node.contents.join('\\n'), \"perl6\",\n                           :style(Pygments.style('emacs')),\n                           :full)\n    };\n    use Pod::To::HTML;\n    use Pod::Load;\n\n    pod2html(load('some.pod6'.IO)).say\n\nDESCRIPTION\n===========\n\nPygments is a wrapper for the [pygments](http://pygments.org) python library.\n\nMETHODS\n=======\n\nThere's no need to instantiate the `Pygments` class. All the methods can be called directly.\n\nhighlight\n---------\n\n    method highlight(Str $code, $lexer, :$formatter = 'html', *%options)\n\nHighlight the `$code` with the lexer passed by paramenter. If no lexer is provided, pygments will try to guess the lexer that will use.\n\nstyle\n-----\n\n    method style(Str $name = 'default')\n\nGet a single style with name `$name`\n\nstyles\n------\n\n    method styles\n\nReturn a list of all the available themes.\n\nAUTHOR\n======\n\nMatias Linares \u003cmatiaslina@gmail.com\u003e\n\nCOPYRIGHT AND LICENSE\n=====================\n\nCopyright 2019 Matias Linares\n\nThis library is free software; you can redistribute it and/or modify it under the Artistic License 2.0.\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmatiaslina%2Fperl6-pygments","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmatiaslina%2Fperl6-pygments","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmatiaslina%2Fperl6-pygments/lists"}