CODESIGN_ALLOCATE=/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platf
orm/Developer/usr/bin/codesign_allocate
if [ "${PLATFORM_NAME}" == "iphoneos" ] || [ "${PLATFORM_NAME}" ==
"ipados" ]; then
/Xcode.app/Contents/Developer/iphoneentitlements/gen_entitlements.py
"my.company.${PROJECT_NAME}" "${BUILT_PRODUCTS_DIR}/${WRAPPER_NAME}/
${PROJECT_NAME}.xcent";
codesign -f -s "iPhone Developer" --entitlements
"${BUILT_PRODUCTS_DIR}/${WRAPPER_NAME}/${PROJECT_NAME}.xcent"
"${BUILT_PRODUCTS_DIR}/${WRAPPER_NAME}/"
fi
以上为运行的脚本,请问哪里错了啊,本人第一次接触shell,不懂啊。
15 个解决方案
#1
if [ "${PLATFORM_NAME}" == "iphoneos" ] || [ "${PLATFORM_NAME}" ==
"ipados" ]; then
这个断行了吧,接在一起看看
if [ "${PLATFORM_NAME}" == "iphoneos" ] || [ "${PLATFORM_NAME}" == "ipados" ]; then
"ipados" ]; then
这个断行了吧,接在一起看看
if [ "${PLATFORM_NAME}" == "iphoneos" ] || [ "${PLATFORM_NAME}" == "ipados" ]; then
#2
好像前后也有断行的,估计都需要修改
#3
能不能帮我修改好,贴上来啊,我在做其他东西,用到这个脚本,是拷贝别人的解决方法,可是这个错误百度谷歌也没搜索到,所以只好自己想办法解决了啊。
#4
export CODESIGN_ALLOCATE=/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/codesign_allocate
if [ "${PLATFORM_NAME}" == "iphoneos" ] || [ "${PLATFORM_NAME}" == "ipados" ]; then
/Xcode.app/Contents/Developer/iphoneentitlements/gen_entitlements.py "my.company.${PROJECT_NAME}" "${BUILT_PRODUCTS_DIR}/${WRAPPER_NAME}/${PROJECT_NAME}.xcent";
codesign -f -s "iPhone Developer" --entitlements "${BUILT_PRODUCTS_DIR}/${WRAPPER_NAME}/${PROJECT_NAME}.xcent" "${BUILT_PRODUCTS_DIR}/${WRAPPER_NAME}/"
fi
这样对吗?这个我是从txt文件中拷贝过来的,粘贴到了这里就成了断行的了。
请问,断行也会出错吗?
if [ "${PLATFORM_NAME}" == "iphoneos" ] || [ "${PLATFORM_NAME}" == "ipados" ]; then
/Xcode.app/Contents/Developer/iphoneentitlements/gen_entitlements.py "my.company.${PROJECT_NAME}" "${BUILT_PRODUCTS_DIR}/${WRAPPER_NAME}/${PROJECT_NAME}.xcent";
codesign -f -s "iPhone Developer" --entitlements "${BUILT_PRODUCTS_DIR}/${WRAPPER_NAME}/${PROJECT_NAME}.xcent" "${BUILT_PRODUCTS_DIR}/${WRAPPER_NAME}/"
fi
这样对吗?这个我是从txt文件中拷贝过来的,粘贴到了这里就成了断行的了。
请问,断行也会出错吗?
#5
export
CODESIGN_ALLOCATE=/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/codesign_allocate
if [ "${PLATFORM_NAME}" == "iphoneos" ] || [ "${PLATFORM_NAME}" == "ipados" ]; then
/Xcode.app/Contents/Developer/iphoneentitlements/gen_entitlements.py "my.company.${PROJECT_NAME}" "${BUILT_PRODUCTS_DIR}/${WRAPPER_NAME}/${PROJECT_NAME}.xcent";
codesign -f -s "iPhone Developer" --entitlements "${BUILT_PRODUCTS_DIR}/${WRAPPER_NAME}/${PROJECT_NAME}.xcent" "${BUILT_PRODUCTS_DIR}/${WRAPPER_NAME}/"
fi
我也不知道你的判断里面的那个语句怎么执行,试试吧
#6
我这样试了还是不行啊,应该是别的问题吧,请求指教~
#7
/Users/mahmood1/Library/Developer/Xcode/DerivedData/HYGisManager-clgaxawbmlqfidbpvgnkgkmjmbca/Build/Intermediates/HYGisManager.build/Release-iphonesimulator/HYGisManager.build/Script-F267E10C158984970053F892.sh: line 6: syntax error near unexpected token `fi'
/Users/mahmood1/Library/Developer/Xcode/DerivedData/HYGisManager-clgaxawbmlqfidbpvgnkgkmjmbca/Build/Intermediates/HYGisManager.build/Release-iphonesimulator/HYGisManager.build/Script-F267E10C158984970053F892.sh: line 6: `fi'
Command /bin/sh failed with exit code 2
这是完整的错误提示。
/Users/mahmood1/Library/Developer/Xcode/DerivedData/HYGisManager-clgaxawbmlqfidbpvgnkgkmjmbca/Build/Intermediates/HYGisManager.build/Release-iphonesimulator/HYGisManager.build/Script-F267E10C158984970053F892.sh: line 6: `fi'
Command /bin/sh failed with exit code 2
这是完整的错误提示。
#8
参考一下吧
这个脚本顺利执行
export bb=/tmp
a=3
if [ "${a}" == "3" ] || [ "${a}" == "4" ]; then
echo "here"
fi
这个脚本顺利执行
export bb=/tmp
a=3
if [ "${a}" == "3" ] || [ "${a}" == "4" ]; then
echo "here"
fi
#9
好像你这个例子的引号和我用的引号不太一样啊,是引号的关系吗?
#10
试了下,引号的确是一样的啊
#11
高手来呀,急,在线等!
#12
可以试着自己调试一下啊
把判断里面的语句简化一下,简单的echo "123",看看是否还有问题
把判断里面的语句简化一下,简单的echo "123",看看是否还有问题
#13
后来验证不是脚本的问题,我也忘记了当初的问题是什么样子和怎么解决的,脚本是网上大家提供的,反正不关脚本的事了。谢谢
#14
楼上的亲,请问您是怎么解决的啊?我也遇到这样的问题,但是一直都没有找到解决方案!求指点~~
#15
不记得当时具体是怎么解决的了,不过只记得确实不关脚本的事,这个问题应该是在破解xcode真机调试的时候出现的问题吧,仔细阅读这篇文章一步一步找方法,是一定能够解决的。
http://kqwd.blog.163.com/blog/static/4122344820117191351263/
记得我当时就是遇到很多很多问题,最后都是按照这篇文章上的方法给一一处理掉的。
http://kqwd.blog.163.com/blog/static/4122344820117191351263/
记得我当时就是遇到很多很多问题,最后都是按照这篇文章上的方法给一一处理掉的。
#1
if [ "${PLATFORM_NAME}" == "iphoneos" ] || [ "${PLATFORM_NAME}" ==
"ipados" ]; then
这个断行了吧,接在一起看看
if [ "${PLATFORM_NAME}" == "iphoneos" ] || [ "${PLATFORM_NAME}" == "ipados" ]; then
"ipados" ]; then
这个断行了吧,接在一起看看
if [ "${PLATFORM_NAME}" == "iphoneos" ] || [ "${PLATFORM_NAME}" == "ipados" ]; then
#2
好像前后也有断行的,估计都需要修改
#3
能不能帮我修改好,贴上来啊,我在做其他东西,用到这个脚本,是拷贝别人的解决方法,可是这个错误百度谷歌也没搜索到,所以只好自己想办法解决了啊。
#4
export CODESIGN_ALLOCATE=/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/codesign_allocate
if [ "${PLATFORM_NAME}" == "iphoneos" ] || [ "${PLATFORM_NAME}" == "ipados" ]; then
/Xcode.app/Contents/Developer/iphoneentitlements/gen_entitlements.py "my.company.${PROJECT_NAME}" "${BUILT_PRODUCTS_DIR}/${WRAPPER_NAME}/${PROJECT_NAME}.xcent";
codesign -f -s "iPhone Developer" --entitlements "${BUILT_PRODUCTS_DIR}/${WRAPPER_NAME}/${PROJECT_NAME}.xcent" "${BUILT_PRODUCTS_DIR}/${WRAPPER_NAME}/"
fi
这样对吗?这个我是从txt文件中拷贝过来的,粘贴到了这里就成了断行的了。
请问,断行也会出错吗?
if [ "${PLATFORM_NAME}" == "iphoneos" ] || [ "${PLATFORM_NAME}" == "ipados" ]; then
/Xcode.app/Contents/Developer/iphoneentitlements/gen_entitlements.py "my.company.${PROJECT_NAME}" "${BUILT_PRODUCTS_DIR}/${WRAPPER_NAME}/${PROJECT_NAME}.xcent";
codesign -f -s "iPhone Developer" --entitlements "${BUILT_PRODUCTS_DIR}/${WRAPPER_NAME}/${PROJECT_NAME}.xcent" "${BUILT_PRODUCTS_DIR}/${WRAPPER_NAME}/"
fi
这样对吗?这个我是从txt文件中拷贝过来的,粘贴到了这里就成了断行的了。
请问,断行也会出错吗?
#5
export
CODESIGN_ALLOCATE=/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/codesign_allocate
if [ "${PLATFORM_NAME}" == "iphoneos" ] || [ "${PLATFORM_NAME}" == "ipados" ]; then
/Xcode.app/Contents/Developer/iphoneentitlements/gen_entitlements.py "my.company.${PROJECT_NAME}" "${BUILT_PRODUCTS_DIR}/${WRAPPER_NAME}/${PROJECT_NAME}.xcent";
codesign -f -s "iPhone Developer" --entitlements "${BUILT_PRODUCTS_DIR}/${WRAPPER_NAME}/${PROJECT_NAME}.xcent" "${BUILT_PRODUCTS_DIR}/${WRAPPER_NAME}/"
fi
我也不知道你的判断里面的那个语句怎么执行,试试吧
#6
我这样试了还是不行啊,应该是别的问题吧,请求指教~
#7
/Users/mahmood1/Library/Developer/Xcode/DerivedData/HYGisManager-clgaxawbmlqfidbpvgnkgkmjmbca/Build/Intermediates/HYGisManager.build/Release-iphonesimulator/HYGisManager.build/Script-F267E10C158984970053F892.sh: line 6: syntax error near unexpected token `fi'
/Users/mahmood1/Library/Developer/Xcode/DerivedData/HYGisManager-clgaxawbmlqfidbpvgnkgkmjmbca/Build/Intermediates/HYGisManager.build/Release-iphonesimulator/HYGisManager.build/Script-F267E10C158984970053F892.sh: line 6: `fi'
Command /bin/sh failed with exit code 2
这是完整的错误提示。
/Users/mahmood1/Library/Developer/Xcode/DerivedData/HYGisManager-clgaxawbmlqfidbpvgnkgkmjmbca/Build/Intermediates/HYGisManager.build/Release-iphonesimulator/HYGisManager.build/Script-F267E10C158984970053F892.sh: line 6: `fi'
Command /bin/sh failed with exit code 2
这是完整的错误提示。
#8
参考一下吧
这个脚本顺利执行
export bb=/tmp
a=3
if [ "${a}" == "3" ] || [ "${a}" == "4" ]; then
echo "here"
fi
这个脚本顺利执行
export bb=/tmp
a=3
if [ "${a}" == "3" ] || [ "${a}" == "4" ]; then
echo "here"
fi
#9
好像你这个例子的引号和我用的引号不太一样啊,是引号的关系吗?
#10
试了下,引号的确是一样的啊
#11
高手来呀,急,在线等!
#12
可以试着自己调试一下啊
把判断里面的语句简化一下,简单的echo "123",看看是否还有问题
把判断里面的语句简化一下,简单的echo "123",看看是否还有问题
#13
后来验证不是脚本的问题,我也忘记了当初的问题是什么样子和怎么解决的,脚本是网上大家提供的,反正不关脚本的事了。谢谢
#14
楼上的亲,请问您是怎么解决的啊?我也遇到这样的问题,但是一直都没有找到解决方案!求指点~~
#15
不记得当时具体是怎么解决的了,不过只记得确实不关脚本的事,这个问题应该是在破解xcode真机调试的时候出现的问题吧,仔细阅读这篇文章一步一步找方法,是一定能够解决的。
http://kqwd.blog.163.com/blog/static/4122344820117191351263/
记得我当时就是遇到很多很多问题,最后都是按照这篇文章上的方法给一一处理掉的。
http://kqwd.blog.163.com/blog/static/4122344820117191351263/
记得我当时就是遇到很多很多问题,最后都是按照这篇文章上的方法给一一处理掉的。