Jump to content


Is there a way to find out who owns (created ) a particular workspace ?

workspace client

  • Please log in to reply
6 replies to this topic

#1 akumar

akumar

    Newbie

  • Members
  • Pip
  • 7 posts

Posted 08 October 2014 - 03:05 AM

As an admin, is there an easy way to find who created a workspace ? Can I use p4 client -i to get this information ?

#2 Thandesha

Thandesha

    Advanced Member

  • Members
  • PipPipPip
  • 164 posts
  • LocationSunnyvale, CA, USA

Posted 08 October 2014 - 08:55 AM

If you know the client name:
$ p4 client -o <client_name> | grep "^Owner:"

If you know the user:
$p4 clients -u <user>

If you know nothing:
$p4 clients  --> This could be heavy command depending on how big is your
installation.

On Wed, Oct 8, 2014 at 8:40 AM, akumar <
perforce-user-forum@forums.perforce.com> wrote:

Quote


Posted on behalf of forum user 'akumar'.

As an admin, is there an easy way to find who created a workspace ? Can I
use p4
client -i to get this information ?



--
Please click here to see the post in its original format:
http://forums.perfor.../topic/3624-is-
there-a-way-to-find-out-who-owns-created-a-particular-workspace
_______________________________________________
perforce-user mailing list  -  perforce-user@perforce.com
http://maillist.perf...o/perforce-user




--
------------------------------------------------------------------------------------
"The only thing worse than losing is quitting"

Your Non-Quitting Friend
Thandesha VK
------------------------------------------------------------------------------------
_______________________________________________
perforce-user mailing list  -  perforce-user@perforce.com
http://maillist.perf...o/perforce-user



#3 akumar

akumar

    Newbie

  • Members
  • Pip
  • 7 posts

Posted 08 October 2014 - 04:47 PM

thanks

#4 P4Shimada

P4Shimada

    Advanced Member

  • Members
  • PipPipPip
  • 831 posts

Posted 10 October 2014 - 07:23 PM

Here are some additional examples of using 'p4 client -i' and the Owner field:

    http://answers.perfo...rkspace-Cloning

#5 Domenic

Domenic

    Advanced Member

  • Members
  • PipPipPip
  • 105 posts

Posted 10 October 2014 - 08:22 PM

Going back to this original question:

View Postakumar, on 08 October 2014 - 03:05 AM, said:

As an admin, is there an easy way to find who created a workspace ? Can I use p4 client -i to get this information ?

I think you'd need to look in your log files to be 100% sure. It is possible to change the owner of a workspace so whoever owns it isn't necessarily the same user who created it. However, depending on the level of accuracy needed and how you intend to use the info just getting the current owner may be sufficient.

#6 P4Shimada

P4Shimada

    Advanced Member

  • Members
  • PipPipPip
  • 831 posts

Posted 10 October 2014 - 11:25 PM

True that the server log will show who created the client. If you use Linux OS you can grep the log for the 'user-client <clientname>' command. For example:

$ cat logs/log | grep "user-client newone"
	2014/10/10 16:18:01 pid 18184 admin@rhw-bruno 000.0.0.1 [p4/2014.1/LINUX26X86_64/821990] 'user-client newone'

If you have the spec depot enabled, you can always look at the date and time stamp there to compare with the log data. For example:


$ p4 filelog //spec/client/newone.p4s
//spec/client/newone.p4s
... #3 default change delete on 2014/10/10
... #2 default change edit on 2014/10/10
... #1 default change add on 2014/10/10

and if you use the -ztag with the command such as:

p4 -ztag filelog //spec/client/newone.p4s

it will show the internal timestamp for the revision.

#7 Robert Cowham

Robert Cowham

    Advanced Member

  • PCP
  • 271 posts
  • LocationLondon, UK

Posted 11 October 2014 - 10:38 PM

If you have a spec depot (and IMO everyone should), then you can look at the first line of version 1 of the client spec.

If you have a client workspace called bruno_ws and a spec depot called specs, then the following will work:

p4 print //specs/client/bruno_ws.p4s#1

The second line will say:

# The form data below was edited by bruno

(or whoever the user was)

The current owner is shown by the Owner: field as previously mentioned.

Regards
Robert
Co-Author of "Learning Perforce SCM", PACKT Publishing, 25 September 2013, ISBN 9781849687645

"It's wonderful to see a new book about Perforce, especially one written by Robert Cowham and Neal Firth. No one can teach Perforce better than these seasoned subject matter experts"
  • Laura Wingerd, author of Practical Perforce, former VP of Product Technology at Perforce





Also tagged with one or more of these keywords: workspace, client

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users