3

oclint生成的html报告结果

xcodebuild -workspace ${myworkspace} -scheme ${myscheme} \ -sdk iphonesimulator \ -derivedDataPath ./build/derivedData \ -configuration Debug \ COMPILER_INDEX_STORE_ENABLE=NO \ | xcpretty -r json-compilation-database -o compile_commands.json

我运行上面的命令行来构建我的项目,它构建成功,但是当我运行下面的命令行来生成 oclint html 报告文件时,得到 15 个编译器错误。

oclint-json-compilation-database -e Pods -- \ -extra-arg=-Wno-error=everything \ -report-type html \ -rc LONG_LINE=200 \ -rule MultipleUnaryOperator \ -max-priority-1=0 \ -max-priority-2=10 \ -max-priority-3=20 \ -o ./oclint_report.html

4

1 回答 1

0

尝试这个

oclint-json-compilation-database <YOUR OPTIONS HERE> -- -extra-arg=-Wno-everything

作为:

oclint-json-compilation-database -e Pods -- \
               -extra-arg=-Wno-error=everything \
               -report-type html \
               -rc LONG_LINE=200 \
               -rule MultipleUnaryOperator \
               -max-priority-1=0 \
               -max-priority-2=10 \
               -max-priority-3=20 \
               -extra-arg=-Wno-everything \
               -o ./oclint_report.html
于 2019-10-16T09:14:55.657 回答