问题标签 [run-script]
For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.
python - 在 Xcode 中运行 iOS 项目之前运行 python HttpServer
我正在尝试在运行 iOS 项目之前运行 http 服务器。我 python -m SimpleHTTPServer 9527
在Run Script
.
当我在终端中运行它时没问题,但是当我
Run
在 Xcode 中单击按钮时,它停止了
当我停止项目时,Xcode 显示了一些错误日志:
在 0.0.0.0 端口 9527 上提供 HTTP ... Traceback(最近一次调用最后一次):文件“/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/runpy.py”,第 162 行,在 _run_module_as_main “主", fname, loader, pkg_name) File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/runpy.py", line 72, in _run_code exec code in run_globals File "/System/ Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/SimpleHTTPServer.py”,第 235 行,在 test() 文件“/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2 .7/SimpleHTTPServer.py”,第 231 行,在测试 BaseHTTPServer.test(HandlerClass, ServerClass) 文件“/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/BaseHTTPServer.py”,行599,在测试 httpd.serve_forever() 文件“/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/SocketServer.py”,第 236 行,在serve_forever poll_interval) 文件“/System/Library /框架/Python。framework/Versions/2.7/lib/python2.7/SocketServer.py",第 155 行,在 _eintr_retry 返回 func(*args) KeyboardInterrupt
请帮助或尝试提供一些想法如何实现这一目标。提前致谢。
ruby - Xcode ruby runscript 找不到 gem
Xcode:9.3.1
操作系统:macOS High Sierra 10.13.4
我是 iOS 开发人员,我对 ruby 一点也不熟悉。
我在我的 Xcode 项目中使用了一个运行脚本,它使用了一个名为“ xcodeproj
”的 ruby gem。在一切正常之前,但我更新了我的 macOS,现在这个运行脚本无法找到 gem 'xcodeproj'
当我尝试构建我的项目时,它显示以下错误
我去了上面错误中显示的路径,并且没有xcodeproj
gem 文件,即使在我安装之后gem install xcodeproj
它也被安装在其他地方。这是我终端上的输出
此外,当我尝试通过终端执行我的 ruby runscript 时,它没有显示错误(并且通过 xcode 失败)。
显然,gemxcodeproj
已安装在我的 macOS 中,但它不在 Ruby.framwork 下,我认为这就是我的 xcode 的运行脚本在构建时失败的原因。Hese 是我的脚本
任何帮助都非常感谢,伙计们:)
xcode - 为什么 Carthage 需要 Run 脚本?
我发现了无数关于如何添加 Carthage Run 脚本的线程,但我想知道为什么需要这个脚本?
将其他 .frameworks 添加到Embedded Binaries
orLinked Frameworks
时,我知道不需要额外的步骤。那么为什么 Carthage 构建的框架不同呢?
查看文档,它谈到了debug information being copied into the built products directory
. 那么这个运行脚本是否需要允许对崩溃日志进行去符号化,或者它是为了其他什么?
ios - 在构建短语中处理不同的配置后找不到有效的 GoogleService-Info.plist
我正在使用 firebase 在应用程序 iOS 中进行标记。
我在 app、dev、prod、preprod、appStore 中有不同的配置。所以我在项目中有几个 GoogleService-Info.plist 。
我在 Resources 文件夹中将它们重命名为 GoogleService-Info-Prod.plist、GoogleService-Info-Dev.plist。
我在项目的构建短语中添加了一个运行脚本,
cp "${SRCROOT}/Test/Resourses/Firebase/GoogleService-Info-$CONFIGURATION.plist" "${SRCROOT}/Test/Resourses/Firebase/GoogleService-Info.plist" 我打算 cp GoogleService-Info 的内容-blabla.plist 到 GoogleService-Info.plist。
但显然,我遇到了这个错误:
2018-07-02 19:05:27.295083+0200 测试 [PROD][63021:19806839] *** 由于未捕获的异常“com.firebase.core”而终止应用程序,原因:“ [FIRApp configure];
(FirebaseApp.configure()
在 Swift 中)找不到有效的GoogleService-Info.plist 在您的项目中。请从https://console.firebase.google.com/下载一个。'
知道我在哪里犯错了吗?非常感谢您的关注。
ios - 使用 Xcode 10 生成 dSYM 后运行脚本阶段(构建时)
在“新功能”部分中,它指出:
- 在新的构建系统中,shell 脚本不能依赖未在其他构建阶段(例如,Info.plist 文件或 .dSYM 文件)中列出的构建工件的状态。添加脚本构建阶段所依赖的文件作为显式输入依赖于 shell 脚本构建阶段。(40852184)
在之前的 Xcode 中,脚本执行成功,但现在可以在 dSYM 文件大小为 0 时执行。
如何让运行脚本阶段仅在生成 dSYM 文件后才开始?
如何按照他们的要求创建“对 shell 脚本构建阶段的显式输入依赖项”?
xcode - 有没有办法避免手动运行“pod install”而不是同时提交 Pods 目录?
在我当前的项目中,我被要求不要提交我的Pods
目录,同时,人们希望我向 XCode 构建阶段“添加一些脚本”,如果需要,它将在每次安装之前自动运行“pod install”。
克隆存储库后,目标不是在终端中手动运行。pod install
我花了一天的时间试图解决这个问题,但我发现了一些没有太多细节的参考资料:
iOS 使用 pod install 作为 Pre-action 运行脚本来构建项目
CocoaPods 版本控制,克隆 repo 时必须使用 pod install
我还发现对于 CI,通过在 .yml 文件中设置操作可以解决相同的问题:
你知道这种脚本会是什么样子吗?
xcode - 使用运行脚本检测自定义配置的调试或发布
如何使用构建阶段/运行脚本检测调试或发布正在运行?
我有四个自定义配置,每个配置都是从发布或调试中复制的。
我找到了这个答案,但它不起作用
xcode - Apollo 的检查并运行 apollo-codegen.sh 不起作用?
我正在尝试在我的 iOS 项目中安装 Apollo。我按照此处的说明进行操作:https ://www.apollographql.com/docs/ios/installation.html 。当我完成“添加代码生成构建步骤”时,出现错误。它找不到文件 check-and-run-apollo-cli.sh。错误是“Command PhaseScriptExecution failed with a nonzero exit code”。所以我检查了它给我的文件路径。似乎“check-and-run-apollo-cli.sh”不存在,但“check-and-run-apollo-codegen.sh”存在。因此,我将项目中脚本的最后一行更改为 check-and-run-apollo-codegen.sh。但是,它仍然不起作用(“命令 PhaseScriptExecution 再次失败,退出代码非零”)。我需要做什么?谢谢。