天天看点

(iOS) AppleDoc生成代码文档

1. 安装AppleDoc

cd ~/Downloads/ && git clone git://github.com/tomaz/appledoc.git && cd ./appledoc && sudo sh install-appledoc.sh

可以通过 appledoc --help 查看相关命令

2.生成docset

appledoc --output ./docset --docset-install-path ./docset --project-name "AppleDoc" --project-company "xyz" --project-version "1.0.0" --no-warn-undocumented-object --no-warn-undocumented-member ./AppleDoc

#--output 输出目录;  --project-name 工程名;--project-version 版本号;--project-company 公司名;

#--no-warn-undocumented-member 没有属性和方法的文件不提示; ./AppleDoc 需要生成代码文档的目录

PS:生成的html就在 docset/x.docset/Contents/Resources/Documents 目录下

Github地址:https://github.com/chenzhe555/iOS-AppleDoc

iOS