是否可以使用dxl脚本(DOORS)为文件夹中的每个模块创建基线? [英] Is it possible to create a baseline for each module in a Folder using a dxl script (DOORS)?

查看:288
本文介绍了是否可以使用dxl脚本(DOORS)为文件夹中的每个模块创建基线?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我需要为文件夹中的每个模块创建一个首次发布"基准,但是我不知道是否可能.至少可以每次为一个模块创建一个基线吗?

提前谢谢

解决方案

是的,很简单. 我假设您基本上了解如何编写DXL脚本,所以这里只是主要部分.始终可以在DXL手册或DXL的developerWorks论坛中找到详细信息和示例(

您没有写模块是仅在一个文件夹中,还是必须递归遍历该文件夹.假设没有递归. 因此,现在您的代码将遍历该文件夹.这是通过

完成的

Itam iCurrent
for iCurrent in fStart do {
    if (type iCurrent == "Formal") {
        myCreateBaselineForModule(module iCurrent)
    }
}

最后,您将需要创建基线. 假设您要创建不带后缀的主版本,请确保当前没有打开任何模块或未保存更改,并且您具有足够的访问权限,代码就是

void myCreateBaselineForModule (Module mod) {
    create (mod, nextMajor(), "")
}

I need to create a "First Release" baseline for each module in a Folder, but I dont know if it is possible. Is, at least, possible to create a baseline for a one module each time?

Thank you in advance

解决方案

yes, it is quite straight forward. I assume that you basically know how to write DXL scripts, so here are just the main parts. Details and examples can always be found in the DXL manual or in the developerWorks forum for DXL (http://www.ibm.com/developerworks/community/forums/html/forum?id=11111111-0000-0000-0000-000000001527)

Your program will mainly consist of a loop that traverses all modules in a folder. Your starting point will be

Folder fStart = folder "/project/myfolder/mysubfolder"

You did not write whether your modules are in one folder only or whether you have to recursively traverse the folder. Assuming no recursion. So, now your code will loop through the folder. This is done via

Itam iCurrent
for iCurrent in fStart do {
    if (type iCurrent == "Formal") {
        myCreateBaselineForModule(module iCurrent)
    }
}

Finally you will need to create a baseline. Assuming you want to create a major version without suffix you are sure that no module is currently open or has unsaved changes and you have enough access rights, the code would simply be

void myCreateBaselineForModule (Module mod) {
    create (mod, nextMajor(), "")
}

这篇关于是否可以使用dxl脚本(DOORS)为文件夹中的每个模块创建基线?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆