pygments:golang 的 pygments 包装器,Pygments 是语法高亮器

时间:2024-07-18 05:33:34
【文件属性】:

文件名称:pygments:golang 的 pygments 包装器,Pygments 是语法高亮器

文件大小:3KB

文件格式:ZIP

更新时间:2024-07-18 05:33:34

Go

色素 golang 的 pygments 包装器 输入 在终端中运行它以安装包 go get github.com/pksunkara/pygments 使用源文件中的以下行导入此包 import "github.com/pksunkara/pygments" 用法 高亮代码 pygments . Highlight ( "code" , "lexer" , "format" , "encoding" ) pygments . Highlight ( "print \" Hello World! \" " , "python" , "html" , "utf-8" ) 提供自定义路径 pygments . Binary ( "/path/to/pygments/binary" ) 文档 访问上的文档 测试 go test 如果您喜欢这个项目,请观看/加星并关注我 贡献者 这是列


【文件预览】:
pygments-master
----.gitignore(252B)
----pygments_test.go(533B)
----LICENSE(1KB)
----README.md(1KB)
----pygments.go(771B)

网友评论