Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我想用 Qt 做一个安装程序。安装程序的配置写在一个名为 installscript.qs 的文件中,该文件基于 qtscript 我试图在里面创建一个 QFile 但它无法识别它!有任何想法吗???
要在安装程序脚本中创建文件,您可以使用以下函数
安装程序.execute()
例如,要创建一个空文件(Linux 平台),调用该函数如下
安装程序.执行(“触摸”,“文件路径”);
或将一些文本消息附加到文件中,调用此函数如下
installer.execute('/bin/sh', new Array('-c', 'echo some-sample-data >> file-path'));