Discussion:
[p4] Obliterating deleted files
Carsten Orthbandt
2002-06-11 15:48:37 UTC
Permalink
I'd like to obliterate only deleted files matching a given
filespec. Is there an easy way to do this?

---
Carsten Orthbandt, Director Development
SEK SpieleEntwicklungsKombinat GmbH
http://www.sek-ost.de

"Wenn ich Visionen habe, gehe ich zum Arzt." - Helmut Schmidt
Paul Bayless
2002-06-11 16:25:14 UTC
Permalink
Carsten,

Jason at Perforce technical support suggested that I create a client spec
with the files in it I wanted to delete, and then issuing a p4 obliterate -y
//client-name/... .

This works well if you want to delete directories. I don't know if
obliterate lets you pass it a whole list of files.

Paul

--------------------------------------------
Paul Bayless ***@enterworks.com
Enterworks, Inc.
Integration Test Manager
-----Original Message-----
Sent: Tuesday, June 11, 2002 11:49 AM
Subject: [p4] Obliterating deleted files
I'd like to obliterate only deleted files matching a given
filespec. Is there an easy way to do this?
---
Carsten Orthbandt, Director Development
SEK SpieleEntwicklungsKombinat GmbH
http://www.sek-ost.de
"Wenn ich Visionen habe, gehe ich zum Arzt." - Helmut Schmidt
_______________________________________________
http://maillist.perforce.com/mailman/listinfo/perforce-user
Chris Trueman
2002-06-11 17:06:56 UTC
Permalink
I would always run the obliterate command without the "-y" option first.
Just to be sure.


Chris.
Post by Paul Bayless
Jason at Perforce technical support suggested that I create a
client spec with the files in it I wanted to delete, and then
issuing a p4 obliterate -y //client-name/... .
J. Bowles
2002-06-11 18:43:36 UTC
Permalink
Post by Paul Bayless
This works well if you want to delete directories. I don't know if
obliterate lets you pass it a whole list of files.
Yes, but it processes the first completely, then the second completely,
then the third, and so on. So for faster elapsed-time, do the "put the
filenames into a client spec and obliterate based on that".

But in general, obliterating things is often a workaround for
a process/procedure that could stand a bit of refinement. Is there
a way to change your processes so that you don't have to expunge
files?

(Think of "obliterate" as being the equivalent of a carpet cleaner
that gets rid of anything dropped onto the carpet. Yes, it's helpful,
but perhaps you should think about why you're eating spaghetti with
tomato sauce in the living room, while you're at it?)

-jab

ps. Don't forget, "obliterate" locks most/all database tables as it
runs. If you want something to go away because you don't think you'll
need it again, consider obsoleting it by changing protections ("p4 protect")
to make it invisible to everyone.
Brian Colfer
2002-06-11 22:30:34 UTC
Permalink
I would be careful of this approach if your client references more than one
branch then it may obliterate a version that you don't want to obliterate.
-----Original Message-----
From: Paul Bayless [mailto:***@enterworks.com]
Sent: Tuesday, June 11, 2002 09:25
To: perforce-***@perforce.com
Subject: RE: [p4] Obliterating deleted files


Carsten,

Jason at Perforce technical support suggested that I create a client spec
with the files in it I wanted to delete, and then issuing a p4 obliterate -y
//client-name/... .

This works well if you want to delete directories. I don't know if
obliterate lets you pass it a whole list of files.

Paul

--------------------------------------------
Paul Bayless ***@enterworks.com
Enterworks, Inc.
Integration Test Manager
-----Original Message-----
Orthbandt
Sent: Tuesday, June 11, 2002 11:49 AM
Subject: [p4] Obliterating deleted files
I'd like to obliterate only deleted files matching a given filespec.
Is there an easy way to do this?
---
Carsten Orthbandt, Director Development
SEK SpieleEntwicklungsKombinat GmbH
http://www.sek-ost.de
"Wenn ich Visionen habe, gehe ich zum Arzt." - Helmut Schmidt
_______________________________________________
http://maillist.perforce.com/mailman/listinfo/perforce-user
_______________________________________________
perforce-user mailing list - perforce-***@perforce.com
http://maillist.perforce.com/mailman/listinfo/perforce-user
Carsten Orthbandt
2002-06-12 07:44:47 UTC
Permalink
This is not a regular task. Usually we do not obliterate files.
But sometimes users add files with wrong names (I'll write a
submit trigger that prevents this) or wrong location (IMHO there's
no way to circumvent this problem). When this happens they simply
add their files with the right path and delete the old ones. Then
the old files should be obliterated. Sometimes these are quite
large lists. Using a special client spec does not work. If it
would, I could also use file specs with wildcards. But the file
names do not match very well.
The only thing that these files have in common is that they
are deleted.
What I really need is a list of all deleted files in a sub dir
so I can edit it and use for obliterate afterwards.

---
Carsten Orthbandt, Director Development
SEK SpieleEntwicklungsKombinat GmbH
http://www.sek-ost.de

"Wenn ich Visionen habe, gehe ich zum Arzt." - Helmut Schmidt
-----Original Message-----
Sent: Tuesday, June 11, 2002 8:44 PM
Subject: RE: [p4] Obliterating deleted files
Post by Paul Bayless
This works well if you want to delete directories. I don't know if
obliterate lets you pass it a whole list of files.
Yes, but it processes the first completely, then the second
completely,
then the third, and so on. So for faster elapsed-time, do the "put the
filenames into a client spec and obliterate based on that".
But in general, obliterating things is often a workaround for
a process/procedure that could stand a bit of refinement. Is there
a way to change your processes so that you don't have to expunge
files?
(Think of "obliterate" as being the equivalent of a carpet cleaner
that gets rid of anything dropped onto the carpet. Yes, it's helpful,
but perhaps you should think about why you're eating spaghetti with
tomato sauce in the living room, while you're at it?)
-jab
ps. Don't forget, "obliterate" locks most/all database tables as it
runs. If you want something to go away because you don't think you'll
need it again, consider obsoleting it by changing protections
("p4 protect")
to make it invisible to everyone.
_______________________________________________
http://maillist.perforce.com/mailman/listinfo/perforce-user
Dave Lewis
2002-06-12 16:15:36 UTC
Permalink
Post by Carsten Orthbandt
This is not a regular task. Usually we do not obliterate files.
But sometimes users add files with wrong names (I'll write a
submit trigger that prevents this) or wrong location (IMHO there's
no way to circumvent this problem). When this happens they simply
add their files with the right path and delete the old ones. Then
the old files should be obliterated. Sometimes these are quite
large lists. Using a special client spec does not work. If it
would, I could also use file specs with wildcards. But the file
names do not match very well.
do you mean that the names are pretty random, so there is no wildcard
which will match the right ones?

you can always have a client spec which maps individual files
Post by Carsten Orthbandt
The only thing that these files have in common is that they
are deleted.
What I really need is a list of all deleted files in a sub dir
so I can edit it and use for obliterate afterwards.
p4 files ... |grep "delete change" might get you there

dave
Post by Carsten Orthbandt
---
Carsten Orthbandt, Director Development
SEK SpieleEntwicklungsKombinat GmbH
http://www.sek-ost.de
"Wenn ich Visionen habe, gehe ich zum Arzt." - Helmut Schmidt
-----Original Message-----
Sent: Tuesday, June 11, 2002 8:44 PM
Subject: RE: [p4] Obliterating deleted files
Post by Paul Bayless
This works well if you want to delete directories. I don't know if
obliterate lets you pass it a whole list of files.
Yes, but it processes the first completely, then the second
completely,
then the third, and so on. So for faster elapsed-time, do the "put the
filenames into a client spec and obliterate based on that".
But in general, obliterating things is often a workaround for
a process/procedure that could stand a bit of refinement. Is there
a way to change your processes so that you don't have to expunge
files?
(Think of "obliterate" as being the equivalent of a carpet cleaner
that gets rid of anything dropped onto the carpet. Yes, it's helpful,
but perhaps you should think about why you're eating spaghetti with
tomato sauce in the living room, while you're at it?)
-jab
ps. Don't forget, "obliterate" locks most/all database tables as it
runs. If you want something to go away because you don't think you'll
need it again, consider obsoleting it by changing protections
("p4 protect")
to make it invisible to everyone.
_______________________________________________
http://maillist.perforce.com/mailman/listinfo/perforce-user
_______________________________________________
http://maillist.perforce.com/mailman/listinfo/perforce-user
Loading...