我正在嘗試編寫一些代碼以將具有特定名稱的子文件夾移動到另一個文件夾。我使用了更改,複製,同步和刪除命令,但我不確定我做錯了什麼。無法使用Perforce命令將文件從一個文件夾移動到另一個文件夾
當我運行此代碼時,我的Perl Tk GUI吐出「Released xxx」,但這些文件夾實際上沒有移動。同時,當我運行這些命令時,即使文件存在於P4V中也無法識別。
這是處理移動的代碼片段。
my $changelistnumber
= qx{(p4 change -o | findstr /C:Description: /C:Change: /C:Client: /C:User: /C:Status: & echo Released $folder) | p4 change -i};
$changelistnumber =~ s/[^0-9]//g;
my $printOutput
= qx{p4 copy -c $changelistnumber -v //syseng/Libraries/Concept/request_for_approval/$libfolderUnreleased/$folder/... //syseng/Libraries/Concept/released/$libfolder/$folder/...};
print "Hello!";
$printOutput
= qx{p4 sync -k //syseng/Libraries/Concept/request_for_approval/$libfolderUnreleased/$folder/...};
print "Hello1";
$printOutput
= qx{p4 delete -c $changelistnumber //syseng/Libraries/Concept/request_for_approval/$libfolderUnreleased/$folder/...};
print "Hello2";
$printOutput = qx{p4 submit -c $changelistnumber};
$d->Label(-text=> "Released $folder")->pack();
路徑名後的三個點「...」的用途是什麼? –
那就是如何在P4V文檔中指定該命令 - https://www.perforce.com/perforce/r16.2/manuals/cmdref/p4_copy.html – Shashank
@HåkonHægland,p4表示「所有文件在這裏和後裔子目錄「 – ikegami