<tfoot id='8FnX3'></tfoot>
<legend id='8FnX3'><style id='8FnX3'><dir id='8FnX3'><q id='8FnX3'></q></dir></style></legend>

      • <bdo id='8FnX3'></bdo><ul id='8FnX3'></ul>

      <small id='8FnX3'></small><noframes id='8FnX3'>

    1. <i id='8FnX3'><tr id='8FnX3'><dt id='8FnX3'><q id='8FnX3'><span id='8FnX3'><b id='8FnX3'><form id='8FnX3'><ins id='8FnX3'></ins><ul id='8FnX3'></ul><sub id='8FnX3'></sub></form><legend id='8FnX3'></legend><bdo id='8FnX3'><pre id='8FnX3'><center id='8FnX3'></center></pre></bdo></b><th id='8FnX3'></th></span></q></dt></tr></i><div id='8FnX3'><tfoot id='8FnX3'></tfoot><dl id='8FnX3'><fieldset id='8FnX3'></fieldset></dl></div>

      Python ClearCase 下载 Vobs Popen 密码 BASH 程序 Sketchy

      时间:2023-07-21

        <bdo id='hRmeZ'></bdo><ul id='hRmeZ'></ul>
        <legend id='hRmeZ'><style id='hRmeZ'><dir id='hRmeZ'><q id='hRmeZ'></q></dir></style></legend>
        <tfoot id='hRmeZ'></tfoot>

          1. <small id='hRmeZ'></small><noframes id='hRmeZ'>

              <i id='hRmeZ'><tr id='hRmeZ'><dt id='hRmeZ'><q id='hRmeZ'><span id='hRmeZ'><b id='hRmeZ'><form id='hRmeZ'><ins id='hRmeZ'></ins><ul id='hRmeZ'></ul><sub id='hRmeZ'></sub></form><legend id='hRmeZ'></legend><bdo id='hRmeZ'><pre id='hRmeZ'><center id='hRmeZ'></center></pre></bdo></b><th id='hRmeZ'></th></span></q></dt></tr></i><div id='hRmeZ'><tfoot id='hRmeZ'></tfoot><dl id='hRmeZ'><fieldset id='hRmeZ'></fieldset></dl></div>
                <tbody id='hRmeZ'></tbody>
              • 本文介绍了Python ClearCase 下载 Vobs Popen 密码 BASH 程序 Sketchy的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                问题描述

                我昨天编写了这个程序,除了由 CRON 运行时,它实际上可以工作.今天,我运行了相同的脚本,但它不起作用.该脚本将在没有任何 Tracebacks 错误的情况下运行,并且它将从 ClearCase 视图复制顶部文件夹 (vob),但不会复制目标文件夹下的文件夹和文件中的实际重要数据.

                I coded this program yesterday and it was actually working except for when run by CRON. Today, I ran the same script and it does not work. The script will run without any Tracebacks Errors, and it will copy the top folder (vob) from the ClearCase view, but none of the actual important data in the folders and files below the target folder.

                这是我的 Python 脚本.

                Here is my Python script.

                def obtainCode(view="My_VIEW", folder="/my_folder"):
                    """Download code from ClearCase's File System and put it on the hard-drive"""
                
                    dest = '/etc/foo'
                    password = 'passwords'
                
                    v1 = subprocess.Popen(['cleartool', 'setview', view], shell=True, stdout=subprocess.PIPE)
                    print "v1 = ", v1
                    print "view maybe set :/"
                
                    c1 = subprocess.Popen(['sudo', '-p', '', '-S', 'cp', '-r', folder, dest], stdin=subprocess.PIPE)
                    c1.stdin.write(password + '
                ')
                    c1.stdin.close()
                    c1.wait()
                
                    #### Close View and Stop Processes ####
                    v2 = subprocess.Popen(['cleartool', 'endview', view], shell=True, stdin=v1.stdout, stdout=subprocess.PIPE)
                
                
                    v2.kill()
                    v1.kill()
                

                有谁知道:1) 出了什么问题 2) 为什么它昨天可以工作,但今天不行 3) 更好的方法?

                Does anyone know: 1) what is going wrong 2) why it would work yesterday but not today 3) a better way to do this?

                感谢您的时间和关注.

                推荐答案

                尽量不要使用setview.
                您不需要它,您可以使用视图的完整路径.

                Try and not use setview.
                You do not need it and you can use the full path of the view instead.

                cleartool startview yourDynamicView
                cd /view/yourDynamicView/vobs/yourVob
                

                我之前提到过使用 setview 的危险(Python 和 ClearCase setview").
                它会在您的子流程中创建一个子流程,此处不需要.

                I have mentioned before the danger of using setview ("Python and ClearCase setview").
                It creates a subprocess within your subprocess, which is not needed here.

                这篇关于Python ClearCase 下载 Vobs Popen 密码 BASH 程序 Sketchy的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

                上一篇:实时拦截子流程输出的问题 下一篇:在子进程中使用 * 通配符的命令问题

                相关文章

              • <legend id='CYHOk'><style id='CYHOk'><dir id='CYHOk'><q id='CYHOk'></q></dir></style></legend>

                <i id='CYHOk'><tr id='CYHOk'><dt id='CYHOk'><q id='CYHOk'><span id='CYHOk'><b id='CYHOk'><form id='CYHOk'><ins id='CYHOk'></ins><ul id='CYHOk'></ul><sub id='CYHOk'></sub></form><legend id='CYHOk'></legend><bdo id='CYHOk'><pre id='CYHOk'><center id='CYHOk'></center></pre></bdo></b><th id='CYHOk'></th></span></q></dt></tr></i><div id='CYHOk'><tfoot id='CYHOk'></tfoot><dl id='CYHOk'><fieldset id='CYHOk'></fieldset></dl></div>
              • <tfoot id='CYHOk'></tfoot>

                    <bdo id='CYHOk'></bdo><ul id='CYHOk'></ul>
                1. <small id='CYHOk'></small><noframes id='CYHOk'>