易配置的虚拟自动化工具
buildbot-UnrealEngine的Python项目详细描述
buildbot UnrealEngine版本
Buildbot插件,使用非真实自动化工具运行命令
安装
pip install buildbot_UnrealEngine
这将启用额外的step命令作为buildbot中的插件(通过from buildbot.plugins import steps
导入)
用法
frombuildbot.pluginsimportstepsfactory=util.BuildFactory()###### Build commandsfactory.addStep(steps.UEBuild("Engine_Location","Path_To_Project.uproject","TargetName",# Additional Parameters, see below))factory.addStep(steps.UERebuild("Engine_Location","Path_To_Project.uproject","TargetName",# Additional Parameters, see below))factory.addStep(steps.UEClean("Engine_Location","Path_To_Project.uproject","TargetName",# Additional Parameters, see below))###### BuildCookRunfactory.addStep(steps.BuildCookRun("Engine_Location","Path_To_Project.uproject",# Additional Parameters, see below))
参数
所有命令共享以下基本参数:
Parameter | Type/Options | Description |
---|---|---|
engine_path | string (required) | The location to the used engine, the path needs to point to the root folder of the engine (in this folder are at least the ^{ |
project_path | string (required) | The absolute location to the uproject file to be used. (Usually a ^{ |
build_platform | string (default ^{ | The platform on which the build itself will run, used to determine which scripts to run |
engine_type | string (default ^{ |
|
生成Cook运行参数
factory.addStep(steps.BuildCookRun(engine_path,project_path,target_platform="Win64",target_config="Development",no_compile_editor=False,compile=None,cook=None,cook_on_the_fly=None,build=False,clean=False,archive=False,archive_directory=None,p4=None,unversioned_cooked_content=False,encrypt_ini_files=False,release_version=None,base_version=None,compressed=False,distribution=False,iterate=False,run=False,devices=None,null_rhi=False,nativize=False,stage=False,map=None,pak=False,prereqs=False,package=False,crash_reporter=False,title_id=None,dlc_name=None,dlc_include_engine=False,extra_args=None,))
Parameter | Type/Options | Description |
---|---|---|
no_compile_editor | bool | If true adds ^{ |
compile | bool | If true adds ^{ |
cook | bool | If true adds ^{ |
cook_on_the_fly | bool | If true adds ^{ |
build | bool | If true adds ^{ |
clean | bool | If true adds ^{ |
archive | bool | If true adds ^{ |
archive_directory | string | If true adds ^{ |
p4 | bool | If true adds ^{ |
unversioned_cooked_content | bool | If true adds ^{ |
encrypt_ini_files | bool | If true adds ^{ |
release_version | string | If set adds ^{ |
base_version | string | If set adds ^{ |
compressed | bool | If true adds ^{ |
distribution | bool | If true adds ^{ |
iterate | bool | If true adds ^{ |
run | bool | If true adds ^{ |
devices | string array | If set adds ^{ |
null_rhi | bool | If true adds ^{ |
nativize | bool | If true adds ^{ |
stage | bool | If true adds ^{ |
map | string array | If set adds `-Map=<The+String+Array> to the command line. Sets the map to include for the cook process. If omitted, used the one specified on the project documentation. |
pak | bool | If true adds ^{ |
prereqs | bool | If true adds ^{ |
package | bool | If true adds ^{ |
crash_reporter | bool | If true adds ^{ |
dlc_name | string | If set adds -DLCName=<DLCName> to the command line. This will cook the specified Plugin as DLC. |
dlc_include_engine | bool | If true adds ^{ |
title_id | string or list of strings | If true adds ^{ |
extra_args | string or list of strings | If set adds the given arguments to the command line. Can be used for custom or missing command line parameters. |
Windows下的开发安装
下载并安装Python 2.7
安装virtualenv
pip install virtualenv
在
.workspace\venv
中创建一个virtualenvmkdir .workspace cd workspace C:\Python27\Scripts\virtualenv.exe venv cd ..\..\ .workspace\venv\Scripts\activate.bat pip install -r requirements.txt
下载PyWin32(对于twisted)并将其安装到您的venv中
easy_install <PATH_TO_pywin32-220.win32-py2.7.exe>
将buildbot(0.9.1版)克隆到某个位置并安装它及其测试设置
git clone https://github.com/buildbot/buildbot.git -b v0.9.1 cd buildbot\master pip install -e . python setup.py test
安装buildbot unrelengine(在buildbot unrelengine repo中)
pip install -e .
现在您可以通过编写
trial buildbot_UnrealEngine.test
对于代码覆盖率,请安装txcovreport:
easy_install http://darcs.idyll.org/~t/projects/figleaf-latest.tar.gz pip install git+https://github.com/jrydberg/txcovreport.git
现在您可以使用
trial --reporter=tree-coverage buildbot_UnrealEngine.test