cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - If community subscription notifications are filling up your inbox you can set up a daily digest and get all your notifications in a single email. X

purge old versions in creo in a base directory and all of its sub folders

ptc-231240
2-Explorer

purge old versions in creo in a base directory and all of its sub folders

I currently have a right click context menu set up for the creo purge command. it works but i have 1400 folders to go through.

is there any way to purge old versions for creo in a base directory and all of its sub folders by running the purge command once?


This thread is inactive and closed by the PTC Community Management Team. If you would like to provide a reply and re-open this thread, please notify the moderator and reference the thread. You may also use "Start a topic" button to ask a new question. Please be sure to include what version of the PTC product you are using so another community member knowledgeable about your version may be able to assist.
ACCEPTED SOLUTION

Accepted Solutions
FPerez
13-Aquamarine
(To:ptc-231240)

HELLO,

For a recursive purge you can use the script below :(change the foders settings)

Else i know that there are freewares on internet to do this.

@echo off

REM set to location of this script

set scriptname=C:\cao\temp\purge_all.bat

REM set to pro/engineer loadpoint

set prodir="C:\CAO\appli\Creo 2.0\Parametric"

if "%1" == "purge" goto p2

cls

call %prodir%\bin\purge.bat

echo.

FOR /D /R %%a IN (*.*) DO call %scriptname% purge "%%a"

:p2

cd %2

echo Purging %2.

echo.

call %prodir%\bin\purge.bat

View solution in original post

20 REPLIES 20

I use a free utility that works well, but is not very intuitive to use. It was written by a German guy/gal(?) and the interface is awkward. But it does purge old versions recursively (into sub folders) and it cleans out files like .logs and .inf and .m_p, etc...

proe dot cad dot de/downloads/DrPurge.html

I am sure there are others - maybe someone will post a better solution for us both!

-Nate

nrollins
12-Amethyst
(To:nrollins)

why am I being moderated today?

"This reply has been hidden. This can happen if the message has been hidden by a moderator, or has been reported as abusive."

?

infuriating - I bet you won't see this one either...

I see you.

but do you see my original post? I still see it as "being moderated"

And I posted a new discussion and it was not moderated...

Not much help from "-" - no other way to get help that I am aware of.

thanks for the feedback.

No, there is a post that I can't see, which I suppose is you.
gward-+2014-06-26+08-48-44.jpg

Nathan - your posts are automatically flagged when you add a link to an external site. It's part of our spam prevention and as you can see your post below was posted without issue.

No need to worry, I'll make sure to continue to review the moderation queue so that posts aren't caught there for too long.

Thanks Ryan.

I thought that might be the case - so I edited the original replacing the periods with the word "dot" - this did not seem to work; I guess the filter is smarter than me...

As you can see, I did post the same info below with no link nor issue. Now I know.

-Nate

Yes, once it's in the moderation queue it's stuck there until we clear the flag, regardless of any edits you make after the fact.

Here is a cleanup batch file. It will only do one folder at a time though. You put it in your folder and double click on it. I don't know how to edit such a file, but this is what it looks like in Notepad. Maybe there's way to edit it so that it can search in subfolders as well?

del *.ICON

del *.rpt

del *.alias2iges

del *.iges2alias

del *.step2alias

del *.alias2step

del *.m_p

del *.bom.*

del *.ger

del *.inf

del *.inf.*

del *.log.*

del *.lst

del *.lst.*

del *.memb

del *.ptd

del *.rel

del *.tst

del *.err

del *.ICON

Del *.LOG

Del *.idx

Del *.xml

purge.bat

I use a free utility that works well, but is not very intuitive to use. It was written by a German guy/gal(?) and the interface is awkward. But it does purge old versions recursively (into sub folders) and it cleans out files like .logs and .inf and .m_p, etc...

proe.cad.de/downloads/DrPurge.html

I am sure there are others - maybe someone will post a better solution for us both!

-Nate

Sorry for the double post - for some reason I am being "moderated" today.

FPerez
13-Aquamarine
(To:ptc-231240)

HELLO,

For a recursive purge you can use the script below :(change the foders settings)

Else i know that there are freewares on internet to do this.

@echo off

REM set to location of this script

set scriptname=C:\cao\temp\purge_all.bat

REM set to pro/engineer loadpoint

set prodir="C:\CAO\appli\Creo 2.0\Parametric"

if "%1" == "purge" goto p2

cls

call %prodir%\bin\purge.bat

echo.

FOR /D /R %%a IN (*.*) DO call %scriptname% purge "%%a"

:p2

cd %2

echo Purging %2.

echo.

call %prodir%\bin\purge.bat

ptc-231240
2-Explorer
(To:FPerez)

just to clarify, could i create this as a batch file and/or run it from a right click context menu outside of creo?

ROBERT HOPKINS wrote:

just to clarify, could i create this as a batch file and/or run it from a right click context menu outside of creo?

Yes, this works fine exactly as you say.

I've actually had it set up as a right-click menu option on a folder in Windows, so you can right-click a folder and just purge it from there.

We had that version purging just the single folder, with another batch file which we ran from the command line to do a recursive purge - reduces the risk of an accidental click purging the whole drive!

there is a free utility that I use - probably constructed with similar code as is shown above. The utility is written by a German individual and its interface and usibility is not the greatess - prett hard to figure out. But it wirks well and I use it regularly. It is called "Dr. Purge" and I think posting a URL get's my reply "moderated" and does not post. A google search for "dr purge" returns several direct references to this utility.

I used to use "SpekanPurge" which worked well, but lost the link to it and found Dr Purge...

Anyone use other utilities that work well?

-Nate

Inoram
14-Alexandrite
(To:nrollins)

on Olaf Corten's site he has a purge tool, it is similar to what I already made myself, so I don't use it. But it appears to have a purge sub directories right-click.

I used to get moderated. Mostly I just take out the dots in the links. They also automatically accept links to other places in communities.ptc.com.

Dale_Rosema
23-Emerald III
(To:dschenken)

This is a link I provided from an earlier post with an older version of Spekan Purge

http://www.prousercarolinas.org/tips/utilities.htm

(When you click on the DOWNLOAD NOW after the Spekan Purge - , it bring up a window with do you want to save Spurge_2.3.exe. I am currently running 2.3)

This is the discussion if you want to read more:

http://communities.ptc.com/message/246418#246418

Thanks, Dale

Dale,

Thank you for this link to Spekan Purge!

-Nate

Announcements
NEW Creo+ Topics: PTC Control Center and Creo+ Portal


Top Tags