GaTTaCa
GaTTaCa

Reputation: 489

Reverse 'p4 where' command

The command p4 where shows the physical location of a file from its perforce path.

Is there a way to do the opposite: i.e. given a physical path (like /home/user/.../file.c), ask p4 if it is mapped to the client view and get its perforce path (in the form of //dev/user/.../file.c) ?

I was thinking of doing a p4 have on the whole client then check if any result would match the path but that seems a bit tedious...

Upvotes: 1

Views: 751

Answers (1)

Krishna
Krishna

Reputation: 1382

p4 where <absolute path> will give the path from depot.

Upvotes: 1

Related Questions