依赖导航

寒江蓑笠翁大约 23 分钟

依赖导航

这部分是对站内收集的第三方库和框架做一个整理分类,方便后续浏览,也欢迎提交pr添加新的项目。

提示

先后顺序不代表排名,好不好用要根据实际体验来看。

Web框架

名称描述仓库
gin最经典的web框架https://github.com/gin-gonic/ginopen in new window
beego国人开发的web框架https://github.com/beego/beegoopen in new window
iris号称最快的web框架https://github.com/kataras/irisopen in new window
echo极简高性能的web框架https://github.com/labstack/echoopen in new window
goji简洁的web框架https://github.com/zenazn/gojiopen in new window
revel高可用的全栈web框架https://github.com/revel/revelopen in new window
buffalo可以简单的构建全栈项目web框架https://github.com/gobuffalo/buffaloopen in new window
hertz具有高性能和强扩展性的微服务 HTTP 框架(字节开源)https://github.com/cloudwego/hertzopen in new window
dotweb一个简单的微型web框架https://github.com/devfeel/dotwebopen in new window
fiberNode.js Express风格的Web框架https://github.com/gofiber/fiberopen in new window

ORM

名称描述仓库
grom开发者友好的ORM库https://github.com/go-gorm/gormopen in new window
xorm简单强大的ORMhttps://gitea.com/xorm/xormopen in new window
entFaceBook开源的ORMhttps://github.com/ent/entopen in new window
sqlx对sql库的强大拓展https://github.com/jmoiron/sqlxopen in new window
beego/ormbeego自带的ormhttps://github.com/astaxie/beego/tree/master/ormopen in new window
rel可拓展的现代ORMhttps://github.com/go-rel/relopen in new window
bunSQL优先的ORMhttps://github.com/uptrace/bunopen in new window

微服务框架

名称描述仓库
kratos云原生微服务框架(B站开源)https://github.com/go-kratos/kratosopen in new window
go-kit一个微服务开发的工具库https://github.com/go-kit/kitopen in new window
kitex高性能和高拓展的微服务框架(字节开源)https://github.com/cloudwego/kitexopen in new window
go-zero云原生微服务框架(七牛云开源)https://github.com/zeromicro/go-zeroopen in new window
go-micro一个国外的微服务框架https://github.com/go-micro/go-microopen in new window
kite微服务框架(很久没更新)https://github.com/koding/kiteopen in new window
dubbo-gojava dubbo在go实现(阿里开源)https://github.com/apache/dubbo-goopen in new window
tarsgotars在go中的实现(腾讯开源)https://github.com/TarsCloud/TarsGoopen in new window
juptiers面向治理的微服务框架(斗鱼开源)https://github.com/douyu/jupiteropen in new window
redsyncredis分布式锁https://github.com/go-redsync/redsyncopen in new window

彩蛋

斗鱼的jupiter是宙斯的名字,是众神之神,而B站的kratos是战神奎托斯的名字,奎托斯后来杀掉了众神之神宙斯。

日志组件

名称描述仓库
logrus结构化日志库https://github.com/sirupsen/logrusopen in new window
zapuber开源的高性能日志库https://github.com/uber-go/zapopen in new window
glog分级执行日志https://github.com/golang/glogopen in new window
zerolog零内存分配的json日志https://github.com/rs/zerologopen in new window
apex/log结构化日志库https://github.com/apex/logopen in new window
lumberjack日志分割库,支持大小分割,日期分割,文件压缩https://github.com/natefinch/lumberjackopen in new window

测试组件

名称描述仓库
testify最流行的测试工具包https://github.com/stretchr/testifyopen in new window
ginkgo现代化的测试框架https://github.com/onsi/ginkgoopen in new window
ramsql基于内存的SQL引擎,主要用于SQL的单元测试https://github.com/proullon/ramsqlopen in new window
go-sqlmock用于测试的SQL Mockhttps://github.com/DATA-DOG/go-sqlmockopen in new window
goconvey在浏览器可视化中测试https://github.com/smartystreets/goconveyopen in new window
go-stress-testing压测工具https://github.com/link1st/go-stress-testingopen in new window

数据处理

名称描述仓库
mapstructuremap与结构体互转https://github.com/mitchellh/mapstructureopen in new window
cast可以很方便的数据类型转换https://github.com/spf13/castopen in new window
deepcopy深度复制https://github.com/mohae/deepcopyopen in new window
copier可以在结构体之间同名字段复制值https://github.com/jinzhu/copieropen in new window
go-pinyin汉字转拼音https://github.com/mozillazg/go-pinyinopen in new window
go-streams流式数据处理https://github.com/reugn/go-streamsopen in new window
stream流式处理https://github.com/xyctruth/streamopen in new window
go-humanize将数据转换成人类可以阅读的格式https://github.com/dustin/go-humanizeopen in new window
uniseg在 Go 中进行 Unicode 文本分段、字包装和字符串宽度计算https://github.com/rivo/unisegopen in new window

数据验证

名称描述仓库
go-playground/validator/v10数据验证器https://github.com/go-playground/validatoropen in new window
go-cmp谷歌开源的用于比较值的库https://github.com/google/go-cmpopen in new window
ozzo-validation基于规则的数据校验库https://github.com/go-ozzo/ozzo-validationopen in new window
go-tagexpr结构体tag验证库https://github.com/bytedance/go-tagexpropen in new window

数据结构

名称描述仓库
gods常见数据结构的实现https://github.com/emirpasic/godsopen in new window
go-datastructures常见数据结构的实现https://github.com/Workiva/go-datastructuresopen in new window
bisetgo中bitsets的实现https://github.com/bits-and-blooms/bitsetopen in new window
bloomgo中bloom filters的实现https://github.com/bits-and-blooms/bloomopen in new window
deque高性能双端队列的实现https://github.com/edwingeng/dequeopen in new window
concurrent-map并发安全的分片map实现https://github.com/orcaman/concurrent-mapopen in new window
samber/loLodash风格的数据处理库,支持泛型https://github.com/samber/loopen in new window
google/btree谷歌实现的BTree库,支持泛型https://github.com/google/btreeopen in new window
gostl像C++STL一样的数据结构库https://github.com/liyue201/gostlopen in new window

数学计算

名称描述仓库
gonum类比numpyhttps://github.com/gonum/gonumopen in new window
decimal高精度浮点数操作库https://github.com/shopspring/decimalopen in new window
crunch一个简化字节和位操作的库https://github.com/superwhiskers/crunchopen in new window
math-engine数学表达式解析计算引擎库https://github.com/dengsgo/math-engineopen in new window

模板引擎

名称描述仓库
pongo2Django风格的模板引擎https://github.com/flosch/pongo2open in new window
acehtml模板引擎https://github.com/yosssi/aceopen in new window
mustachemustache在go中的实现https://github.com/hoisie/mustacheopen in new window
hero功能强大,快速的模板引擎https://github.com/shiyanhui/heroopen in new window
quictemplate顾名思义,高性能的模板引擎https://github.com/valyala/quicktemplateopen in new window
amber源于HAML和Jade的模板引擎https://github.com/eknkc/amberopen in new window

缓存组件

名称描述仓库
golang-lru线程安全的LRU,以及LRU 2Q 缓存https://github.com/hashicorp/golang-lruopen in new window
ttlcache基于内存的缓存,支持TTL,泛型https://github.com/jellydator/ttlcacheopen in new window
gocache缓存中间件管理器https://github.com/eko/gocacheopen in new window
go-cache基于内存的缓存,适用于单机应用,支持TTLhttps://github.com/patrickmn/go-cacheopen in new window
ristretto高性能的内存缓存https://github.com/dgraph-io/ristrettoopen in new window
bigcache基于内存的高效率的大key缓存https://github.com/allegro/bigcacheopen in new window

数据库&驱动

名称描述仓库
modernc.org/sqliteopen in new windowsqlite驱动,纯go编写,不需要cgohttps://gitlab.com/cznic/sqliteopen in new window
mattn/go-sqlite3sqlite驱动,需要cgohttps://github.com/mattn/go-sqlite3open in new window
denisenkom/go-mssqldbsqlserver驱动,不怎么更新了,建议使用微软的版本https://github.com/denisenkom/go-mssqldbopen in new window
microsoft/go-mssqldbsqlserver驱动,微软fork的新分支并维护https://github.com/microsoft/go-mssqldbopen in new window
pgxpostgreSQL驱动https://github.com/jackc/pgx/open in new window
mysqlmysql驱动https://github.com/go-sql-driver/mysqlopen in new window
oci-go-sdkoracle官方驱动https://github.com/oracle/oci-go-sdkopen in new window
go-oraoracle驱动,纯go编写https://github.com/sijms/go-oraopen in new window
badger嵌入式的kv数据库,基于LSMhttps://github.com/dgraph-io/badgeropen in new window
boltdb嵌入式的kv数据库,基于B+Treehttps://github.com/boltdb/boltopen in new window
goleveldbgo语言实现的leveldbhttps://github.com/syndtr/goleveldbopen in new window
qmgo七牛云开源的mongodb操作库https://github.com/qiniu/qmgoopen in new window
mongo-go-drivermongodb官方的go驱动https://github.com/mongodb/mongo-go-driveropen in new window
rqlite基于sqlite的轻量级分布式关系数据库https://github.com/rqlite/rqlite/open in new window
go-mysql一个强大的MySQL工具集合https://github.com/go-mysql-org/go-mysqlopen in new window
go-mysql-elasticsearchMySQL数据同步到Elasticsearch的工具https://github.com/go-mysql-org/go-mysql-elasticsearchopen in new window
gofound单机亿级全文检索引擎,https://github.com/sea-team/gofoundopen in new window
bleve全文检索库https://github.com/blevesearch/bleveopen in new window

序列化

名称描述仓库
go-iniini文件序列化库https://github.com/go-ini/iniopen in new window
sonic字节开源的高性能json序列化库https://github.com/bytedance/sonicopen in new window
easyjsonjson快速序列化库https://github.com/mailru/easyjsonopen in new window
gjson快速获取json键值,非传统的序列化库https://github.com/tidwall/gjsonopen in new window
go-yamlyaml序列化库https://github.com/go-yaml/yamlopen in new window
go-tomltoml序列化库https://github.com/pelletier/go-tomlopen in new window
propertiesproperties序列化库https://github.com/magiconair/propertiesopen in new window
viper支持多种数据格式序列化,同时也是配置管理器https://github.com/spf13/viperopen in new window
configorgorm作者写的多种数据格式序列化器,配置管理器https://github.com/jinzhu/configoropen in new window

命令行

名称描述仓库
pflagPOSIX/GUN的风格的flag包https://github.com/spf13/pflagopen in new window
go-flags命令参数解析器https://github.com/jessevdk/go-flagsopen in new window
cobra现代命令行程序构建脚手架https://github.com/spf13/cobraopen in new window
dimiro1/banner美观的banner构建库https://github.com/dimiro1/banneropen in new window
go-pretty输出美观的命令行表格,文字,进度条https://github.com/jedib0t/go-prettyopen in new window
progressbar线程安全的命令行进度条https://github.com/schollz/progressbaropen in new window
go-ansi用于 Go 语言的 Windows 便携式 ANSI 转义序列实用程序https://github.com/k0kubun/go-ansiopen in new window
go-isatty用于判断tty的库https://github.com/mattn/go-isattyopen in new window

压缩解压

名称描述仓库
klauspost/compress对compress标准库的优化改造https://github.com/klauspost/compressopen in new window
alexmullins/ziparchive/zip标准库的fork分支,支持密码https://github.com/alexmullins/zipopen in new window
mholt/archiver支持很多格式的压缩解压缩工具库(个人非常推荐)https://github.com/mholt/archiveropen in new window
go-carCAR归档文件在go中的实现https://github.com/ipld/go-caropen in new window
go-unarr一个压缩解压缩库https://github.com/gen2brain/go-unarropen in new window
xz用于读写 xz 压缩文件的纯 Golang 库https://github.com/ulikunitz/xzopen in new window

时期时间

名称描述仓库
carbon时间日期处理库https://github.com/golang-module/carbonopen in new window
robfig/cron定时任务库https://pkg.go.dev/github.com/robfig/cron/v3open in new window
gron定时任务库https://github.com/roylee0704/gronopen in new window
jobrunner异步定时任务框架https://github.com/bamzi/jobrunneropen in new window
dataparse可以在不知道格式的情况下解析时间字符串https://github.com/araddon/dateparseopen in new window
jinzhu/now日期工具库https://github.com/jinzhu/nowopen in new window

依赖注入

名称描述仓库
diguber开源的依赖注入库,基于反射https://darjun.github.io/2020/02/22/godailylib/dig/open in new window
wire谷歌开源的依赖注入库,基于代码生成https://github.com/google/wireopen in new window
inject依赖注入工具https://github.com/codegangsta/injectopen in new window
di依赖注入容器https://github.com/sarulabs/diopen in new window

地理位置

名称描述仓库
geoip2-golangIP转地理信息https://github.com/oschwald/geoip2-golangopen in new window
ip2location-goIP转地理信息https://github.com/ip2location/ip2location-goopen in new window

爬虫框架

名称描述仓库
colly简单强大的爬虫框架https://github.com/gocolly/collyopen in new window
goquery类似j-thinghttps://github.com/PuerkitoBio/goqueryopen in new window

网络工具

名称描述仓库
gentleman插件驱动,可拓展的http客户端https://github.com/h2non/gentlemanopen in new window
restyrestful http 客户端https://pkg.go.dev/github.com/go-resty/resty/v2open in new window
gopeed支持所有平台的现代下载管理器,基于go和flutterhttps://github.com/GopeedLab/gopeedopen in new window

电子邮件

名称描述仓库
jordan-wright/email健壮灵活的邮件发送库https://github.com/jordan-wright/emailopen in new window
gomail邮件发送库https://github.com/go-gomail/gomailopen in new window
go-simple-mail简单的邮件发送库https://github.com/xhit/go-simple-mailopen in new window
go-mail易于使用,全面的邮件发送库https://github.com/wneessen/go-mailopen in new window
email-verifier验证邮箱是否有效,且不需要发送邮件https://github.com/AfterShip/email-verifieropen in new window
maddy组合式的邮件服务器https://github.com/foxcpp/maddyopen in new window
mox全面开源,高维护性,自托管的邮件服务端https://github.com/mjl-/moxopen in new window
hermes邮件模板生成库https://github.com/matcornic/hermesopen in new window
listmonk高性能,子托管,可视化的邮件列表管理https://github.com/knadh/listmonkopen in new window
go-smtpgo编写的SMTP客户端与服务端https://github.com/emersion/go-smtpopen in new window
go-imapgo编写的IMAP客户端与服务端https://github.com/emersion/go-imapopen in new window

游戏开发

名称描述仓库
ebitengine一个超级简单的2d游戏引擎https://github.com/hajimehoshi/ebitenopen in new window
Azul3D一个由go编写的3d游戏引擎https://github.com/azul3d/engineopen in new window
engo由go编写的开源2d游戏引擎https://github.com/EngoEngine/engoopen in new window
g3n/enginego3d游戏引擎https://github.com/g3n/engineopen in new window
gonet一个游戏服务端框架https://github.com/xtaci/gonetopen in new window
leaf游戏服务端框架https://github.com/name5566/leafopen in new window
cloud-game基于web的云游戏服务https://github.com/giongto35/cloud-gameopen in new window

GUI

名称描述仓库
fyne跨平台的GUI开发工具箱(真有点东西)https://github.com/fyne-io/fyneopen in new window
go-flutter用go写flutterhttps://github.com/go-flutter-desktop/go-flutteropen in new window

系统交互

名称描述仓库
gopsutil获取操作系统信息,兼容主流系统https://github.com/shirou/gopsutilopen in new window
flock基于操作系统调用的文件锁https://github.com/gofrs/flockopen in new window
sys官方的操作系统交互库https://cs.opensource.google/go/x/sysopen in new window

跨语言交互

名称描述仓库
gopher-luago编写的lua虚拟机https://github.com/yuin/gopher-luaopen in new window
go-luago编写的lua虚拟机https://github.com/Shopify/go-luaopen in new window
goja支持es5.1+https://github.com/dop251/gojaopen in new window
tengoTengo 是一种小型、动态、快速、安全的 Go 脚本语言https://github.com/d5/tengoopen in new window
goby受ruby启发,由go实现的一种解释型脚本语言https://github.com/goby-lang/gobyopen in new window
go+七牛云开源的脚本语言,可以与go无缝交互,又称Q语言https://github.com/goplus/gopopen in new window
go-pythongo调用cpython2https://github.com/sbinet/go-pythonopen in new window
go-pytyon3go调用cpython3https://github.com/DataDog/go-python3open in new window

图像处理

名称描述仓库
plot一个绘图库,多用于数据可视化https://github.com/gonum/plotopen in new window
gg2d绘图库https://github.com/fogleman/ggopen in new window
gocv支持opencv4+https://github.com/hybridgroup/gocvopen in new window
imaging一个简单的图像处理库https://github.com/disintegration/imagingopen in new window

文字处理

名称描述仓库
vale语法感知的文本校对工具https://github.com/errata-ai/valeopen in new window

认证授权

名称描述仓库
casbin灵活强大的权限管理库https://github.com/casbin/casbinopen in new window
openfga高性能权限/授权库,源于oogle Zanzibarhttps://github.com/openfga/openfgaopen in new window

代码生成

名称描述仓库
jennifer代码生成库https://github.com/dave/jenniferopen in new window

正则处理

名称描述仓库
commonregx一个收集了常用的正则表达式的库https://github.com/mingrammer/commonregexopen in new window

文件处理

名称描述仓库
filebox文件操作工具库https://github.com/dstgo/fileboxopen in new window
size快速完成文件大小与字符串之间的转换https://github.com/dstgo/sizeopen in new window
checksum一个计算文件哈希签名的库https://github.com/codingsince1985/checksumopen in new window
pdfcpupdf处理器https://github.com/pdfcpu/pdfcpuopen in new window
uniofficeoffice处理库https://github.com/unidoc/uniofficeopen in new window
gooxmloffice处理库https://github.com/carmel/gooxmlopen in new window
pdfcpuPDF处理库https://github.com/pdfcpu/pdfcpuopen in new window

通用工具

名称描述仓库
lancet多功能工具库,类比java中的common包https://github.com/duke-git/lancetopen in new window
bytebufferpool字节缓存池https://github.com/valyala/bytebufferpoolopen in new window

开发框架

名称描述仓库
goframe现代企业级go开发框架https://github.com/gogf/gfopen in new window

共识协议

名称描述仓库
hashicorp/raftconsul开源的raft库https://github.com/hashicorp/raftopen in new window
hashicorp/memberlistconsul开源的gossip库https://github.com/hashicorp/memberlistopen in new window
etcd-io/raftetcd开源的raft库https://github.com/etcd-io/raftopen in new window

OCR

名称描述仓库
gosseract使用 Tesseract C + + 库的OCR库https://github.com/otiai10/gosseractopen in new window