Hi,

are there any alternative modules for D7?

Files: 

Comments

NancyDru’s picture

None that I am aware of. This one will get done, just not today.

basicmagic.net’s picture

subscribe

animelion’s picture

subscribe, found this article but don't know how to use it
http://www.fivepaths.com/drupal-revision-removal-and-database-cleanup-by...

giorgio79’s picture

You can easily create a Views for revisions, when adding a new view you just select revision based instead of node based...

Add a VBO to it and you have a super flexible revision manager...

deminy’s picture

subscribe

snupy’s picture

subscribe

Liliplanet’s picture

subscribe thx!

robert.laszlo’s picture

This would be helpful. What's the status of D7 port?

djg_tram’s picture

Is there any known activity on a D7 port? If not, I'll look into it but I wouldn't like to duplicate efforts.

NancyDru’s picture

I still don't have Git working, so I have not started this yet.

djg_tram’s picture

I only have a sandbox project of my own in Git but it seems to work all right. I'm on Windows.

I started to port, the mere syntactic part (database manipulations) is done, it's theoretically running but I get a seemingly infinite loop on the settings page (stuck in the list of all nodes eligible for deletion). I'll pick it up tomorrow because it's getting late around here.

NancyDru’s picture

I haven't even figured out how to get Smartgit to retrieve the module to the right place to work on...

djg_tram’s picture

That I don't know, either, because I never tried. I use plain Git, with a Git GUI frontend, it must have come from http://code.google.com/p/msysgit/. Installed, followed the instructions on the Drupal project page and it works. Took a couple of minutes to find out how to check in modified files but it's fairly straightforward. I'd be glad to try to help you out in private msg or e-mail if needed.

djg_tram’s picture

I have the port ready. As far as I can tell, it's complete, although for reasons of security, the actual deletion is commented out (but it writes into the watchdog as if it was really done). I'd like to show it to you first before I upload it here. Shall I send it by PM here?

NancyDru’s picture

Why not zip or tar it and attach it here so several others can test it too?

djg_tram’s picture

Why not.

Lines 228 and 234 of revision_deletion.module have the comments around the actual deletion. By removing those lines it will delete, too.

Apart from the changes mandated by D7 (both internal like new database layer and visible like the deprecation of the Reset button in Settings, slightly modified URL for the settings page), there is only one major change: deleting now asks for confirmation before execution. Minor changes are like differences in UI wording and changing toggle setting options to checkboxes instead of yes/no radio buttons.

djg_tram’s picture

StatusFileSize
new7.25 KB
NancyDru’s picture

Thank you, Gábor. I will start testing in a day or so. Have to build something to test it with first.

dropbydrop’s picture

Did anyone try #17? is it safe?

animelion’s picture

dropbydrop, did you bite the bullet and try it? :) Wondering the same thing myself.

dropbydrop’s picture

I didn't

djg_tram’s picture

As it is uploaded there, it doesn't actually delete, just lists what it should delete, unless you make the manual changes outlined in #16. So it should be safe to try... :-)

Wolfgang Reszel’s picture

Hi, I tried #17 with removing the comments. I'll get the following error:

Call to undefined function node_invoke_nodeapi()

Pixeljumper’s picture

Hi,

Any update on the Drupal 7 version?

djg_tram’s picture

Ooops, that was a Drupal 6 function and I didn't notice it just because it was commented out. Sorry. Just remove the whole line.

As far as I can tell, with that modification it works all right. If NancyDru would commit it or allow me to do so, I'd be glad to have it available. But do test it first... :-)

NancyDru’s picture

If you notice, I don't own the module, so I can't grant you commit access. Since I have some SAs (other modules) to process shortly, I may be forced to learn Git and then perhaps I can do it.

Steven Jones’s picture

Just wanted to note that I needed a tool that would remove all non-current revisions of nodes on my D7 site, and I just wrote this quick little module: http://drupal.org/sandbox/darthsteven/1468938 that works through the UI and has a drush command. It's currently deleting 900,000 excess revisions from a site with only 10,000 nodes, and is working just fine.
It doesn't have any of the 'garbage collection' features of this module though.

dropbydrop’s picture

@Steven Jones could you make it a module?

Steven Jones’s picture

@dropbydrop it is.

dropbydrop’s picture

@Steven Jones
I mean do you plan for future to make it a module that can be installed through drush etc?
thanks

NancyDru’s picture

You are welcome to co-maintain this module.

Steven Jones’s picture

@NancyDru thanks for the offer, but I'm not sure I want to have another module to maintain, sorry.

@dropbydrop Sorry, but I don't want to make my sandbox a full project that would basically duplicate this one, but the code is there, and you are free to use it or free to incorporate it into this module.

Wolfgang Reszel’s picture

Thanks for your sandbox module. It's exactly what I wanted and very useful when deploying a new website.

kingdee40’s picture

Tried #17 and removed comments between line 228 and 234 but it doesn't delete anything. It's still saying "There do not appear to be any revisions to delete or your selected revisions were deleted by another administrator."

sterndata’s picture

subscribe

ar-jan’s picture

@sterndata: please use the Follow button on the top right of the page...

seworthi’s picture

I just found this: Node Revision Delete
Its a D7 only module. I have not installed or tested, just posting information.
http://drupal.org/project/node_revision_delete

Elijah Lynn’s picture

Good find Seworthi, I will check it out soon!

Thanks

csander’s picture

Could you elaborate on this at all?

HyperGlide’s picture

Any update on the status of this thread and patch?

Thanks,
Hg

Elijah Lynn’s picture

I think it is best to look at #37 ^^.

HyperGlide’s picture

Looked at #37 also created #1875468: Integrate support for node_revision_delete and workbench_moderation. there is a limitation when using with the Workbench_Moderation module.

Lukas von Blarer’s picture

Is the port working?

gifad’s picture

StatusFileSize
new8.33 KB

Hi All,

While upgrading a site to D7, I used port #17 to set up a working version;
I had to :
- finish adapt to D7 API (node_load() ...)
- fix some typos
- most important, use the (new to D7) function node_revision_delete(), which does the hard job (mostly deal with field_revision_body table, where all these megabytes are...)

Used for 3 month in production sites, with no trouble - but "use at your own risks", i.e. at least make a backup before using...

kind regards,

lolandese’s picture

Status:Active» Needs review

Ref. #44.

NancyDru’s picture

Version:6.x-1.x-dev» 7.x-1.x-dev
Status:Needs review» Fixed

Committed with attribution.

Lukas von Blarer’s picture

Status:Fixed» Needs review

I can't see a commit for this... Did you push it?

NancyDru’s picture

Lukas von Blarer’s picture

Sorry, somehow missed it... All perfect.

HyperGlide’s picture

Title:Alternatives for Drupal 7» Revision Deletion - Alternatives for Drupal 7

Status:Fixed» Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.