首先,修改tag
git tag -a 0.1.18 -m "tag"
git push origin 0.1.18
如图,推送到远端的tag
执行
pod spec lint /Users/liubo/Desktop/XBRollingView/XBRollingView.podspec --sources=https://gitee.com/liuboliu/lxbrolling-view-spec.git --allow-warnings 之后
报错 fatal: Remote branch 0.1.17 not found in upstream origin
然后删除 0.1.18 tag
git tag -d 0.1.18
git push origin :refs/tags/0.1.18
重新打tag
git tag -a 0.1.17 -m "tag"
git push 0.1.17
之后在进行远程校验
pod spec lint /Users/liubo/Desktop/XBRollingView/XBRollingView.podspec --sources=https://gitee.com/liuboliu/lxbrolling-view-spec.git --allow-warnings
结果通过
然后又改了一下,将本地的版本号改为0.1.16 再去校验,也是可以通过的,
由此可知,校验的时候,是用本地文件中tag 和远程git 打的tag做校验,并不是和远端的 文件中的tag 做校验,而且需要远端有本地的tag, 并不一定和远端最新的tag 对应