Perforce 中的 Overlay Mappings 设置

Perforce 中的 Overlay Mappings 设置

在 Perforce 可以把多个 depot 位置映射到同一个 workspace 的位置。这种做法称为: Overlay Mapping ,在 “ View work space mapping as text ”窗口中,在映射条目前加一个“ + ”号就可以了。

You could look at overlay mappings, and maybe work around your problem:

An overlay mapping is used to map files from more than one depot directory into the same place in the workspace.

//depot/dir1/... //cws/build/...
+//depot/dir2/... //cws/build/...

In Perforce, you can have a many-to-one mapping but you cannot have a one-to-many mapping. You cannot sync same file to 2 locations. you need to provide it explicit list of what you want to sync. Something like this:

//depot/adir/... //cws/build/AA/adir/...
+//depot/adir/exception.c //cws/build/BB/adir/exception.c

Using wildcards in workspace views

WildcardDescription
*匹配除斜线(目录分隔符)外的任意字符。 Matches anything except slashes. Matches only within a single directory. Case sensitivity depends on your platform.
Matches anything except slashes. Matches only within a single directory. Case sensitivity depends on your platform.
%%1 - %%9Positional specifiers for substring rearrangement in filenames.

*%%1 的区别在于,前者可以匹配目录,而后者不匹配目录。

参考

how to write this perforce client spec?

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值