英文:
Is it possible to map a Perforce depot subpath to the workspace root folder?
问题
在具有如下文件夹结构的仓库中:
depot
subFolder1
subSubFolder1
subSubFolder2
subfolder2
是否可以将 //depot/subFolder1/...
映射到本地文件系统的工作空间根目录,以便它直接包含 subSubFolder1
和 subSubFolder2
?
我正在尝试为虚拟流指定映射。我尝试了以下的 paths
映射,但由于某种原因它将整个仓库映射到了根目录。
exclude ...
import+ ... //depot/subFolder1/...
然而,像这样的映射可以将 subFolder1
映射到工作空间根目录中的 一个子文件夹(而不是 直接 到根目录,这是我想要的):
exclude ...
import+ subFolder1/... //depot/subFolder1/...
注意:如果虚拟流中不支持此操作,但在非流式工作空间映射中支持,也请告诉我,这也是可接受的解决方案。
英文:
In a depot with a folder structure like:
depot
subFolder1
subSubFolder1
subSubFolder2
subfolder2
Is it possible to map just //depot/subFolder1/...
to the workspace root on the local filesystem, so that it will contain directly subSubFolder1
and subSubFolder2
?
I am trying to specify the mapping for a virtual stream. I tried the following paths
mapping, but it maps the whole depot to the root for some reason.
exclude ...
import+ ... //depot/subFolder1/...
However, a mapping like this works to map subFolder1
to a subfolder in the workspace root (not directly to the root, which is what I want):
exclude ...
import+ subFolder1/... //depot/subFolder1/...
Note: If this isn't possible with a virtual stream, but is possible in a non-stream workspace mapping, please let me now, it's also an acceptable solution.
答案1
得分: 2
In theory you would be able to do this in a virtual stream (this is assuming that subFolder1
is a folder in the parent stream's Paths
, not in the depot root) with a Remapped
line:
Type: virtual
Paths:
share subFolder1/...
Remapped:
subFolder1/... ...
but there is currently a (long-standing) bug that doesn't allow Remapped
to work when the target is the root; you can remap the root to a subfolder, or any subfolder to any other subfolder, but unfortunately if you try to remap a subfolder to the root as above you get the error:
View '/...' must be relative and not contain leading slashes
so this is not presently workable.
In a classic client view it's simple:
View:
//depot/subFolder1/... //your-client/...
英文:
In theory you would be able to do this in a virtual stream (this is assuming that subFolder1
is a folder in the parent stream's Paths
, not in the depot root) with a Remapped
line:
Type: virtual
Paths:
share subFolder1/...
Remapped:
subFolder1/... ...
but there is currently a (long-standing) bug that doesn't allow Remapped
to work when the target is the root; you can remap the root to a subfolder, or any subfolder to any other subfolder, but unfortunately if you try to remap a subfolder to the root as above you get the error:
View '/...' must be relative and not contain leading slashes
so this is not presently workable.
In a classic client view it's simple:
View:
//depot/subFolder1/... //your-client/...
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论