Why can't Perl find my file that is in ClearCase?

后端 未结 2 1131
没有蜡笔的小新
没有蜡笔的小新 2020-11-22 14:19

This piece of Perl is telling me that a file in ClearCase doesn\'t exist when it does;

$x = \"PATH/TO/FILE\"
if (-e $x) {
   print \"This file exists on the          


        
2条回答
  •  春和景丽
    2020-11-22 14:59

    Clearcase stores its 'files' as directories

    What Aric is trying to tell you is that ClearCase uses extended path names, "extended" because it extends the file name with version path.

    So in a dynamic view, any file can be described to reveal its versioning path:

    $ ct ls
    myFile
    $ ct descr -l myFile
    myFile@@/main/3
    

    In a dynamic view, you can actually explore the versions of a file (hence the "file as directories") part

    $ cd myFile@@
    $ ls
    main
    $ cd main
    $ ls
    3
    $ cat 3
    ... // content of third version of myFile
    

    Now, if ClearQuest (the issue tracking system) were used here, it would reference activities (change set of file set) of ClearCase.

    But with ClearCase, a version of a file (referenced by ClearQuest or obtained through another mean) can very well has been deleted in the dynamic view ("rmnamed" actually).
    Meaning a file may be referenced by ClearQuest or by some ClearCase activity, but not be visible directly with ClearCase in the dynamic view.
    However, its extended path name would still be accessible in that same dynamic view.

提交回复
热议问题