Hi,
I can't install the module.

Drush MM calls for Drush as a dependency. But Drush is not in module list.

Should the drush_mm.info file be changed to look like this:

name = Drush extras
description = Useful Drush commands. Requires Drush core.
package = Development
core = 6.x

CommentFileSizeAuthor
#10 drush_mm.tar_.gz12.36 KBchiddicks
#7 drush_mm.2x.patch4.88 KBspiderman

Comments

Alice Heaton’s picture

Title: Drush mm has Drush as dependency. But Drush is not in module list » Port to Drush 2.x

Same issue.

It seems that Drush mm only works with Drush 1.x (which installs as a module) and you're using Drush 2.x (which does not install as a module).

Simply changing drush_mm.info as you suggest does not seem to be sufficient - mm does not appear in the available drush commands after being installed. I guess the drush_mm project needs to ported properly to work with drush 2.x.

I'm changing the issue title to reflect this.

socialnicheguru’s picture

Priority: Normal » Critical

Hmmm... there is a 6x version. I thought it was just a mistake in the .info file. I am going to change this to critical since you can't use the module.

Alice Heaton’s picture

Well, I can use the module with Drush 1.x (for which there is a Drupal 6 version) but not with Drush 2.x - so it's fine, I've just reverted to using Drush 1.x

At this time, there is no particular feature of Drush 2.x I need - and it's only in alpha - so this is not urgent for me.

Thanks :)

clemens.tolboom’s picture

Assigned: Unassigned » clemens.tolboom
Priority: Critical » Normal

It's not urgent but would be handy to have available.

I ran into this too ... just reverted back to drush 6.x-1.x ... I guess I have to move all code into an .inc file instead of a module.

As I asked in #367982: Is there documentation about the reasoning for the new structure? I hope to learn why the dependencies are gone ... because I like dependencies as a way of controlling things. With drush this is now gone. Same reason why I hope to patch for an extra info file line like versions[drush_mm]= <drush-6.x-2.x :-)

So any suggestion welcome for a drush_mm-6.x-2.x ...

Alice Heaton’s picture

So any suggestion welcome for a drush_mm-6.x-2.x ...

Could it be possible to rename the command to 'pm' ??? I guess you'd have to ask the pm people, but it would make life simpler :) I sometimes get confused about which command is 'pm' and which is 'mm' :)

Thanks for this module btw, it's really great !!!

clemens.tolboom’s picture

Renaming is not an option for me. The reason is simple. At least for me. This is another module (mm) with a complete other purpose. pm does things with packages (of modules). mm does things with modules.

spiderman’s picture

Status: Active » Needs review
StatusFileSize
new4.88 KB

I managed to get this module working in Drush 2.x without much trouble, simply by changing the name of the drush_mm.module file to mm.drush.inc (to comply with the new naming convention) and modifying the file slightly. Attached is a patch indicating the changes I made.

clemens.tolboom’s picture

Assigned: clemens.tolboom » Unassigned
Status: Needs review » Needs work

Thanks for the patch but the patch _moves_ function which makes it hard to read.

Could you please provide a 'by function' ordered patch :)

Macronomicus’s picture

@ spiderman
I applied your patch but it still appears grayed out on the admin/build/modules page.

I had to edit the drush_mm.info file and comment out the dependencies to
//dependencies[] = drush

I have no mm commands available though, but I get a successful install @ admin/build/modules. Suppose I'll have to wait until this mods compatible with the new drush.
>_<

chiddicks’s picture

StatusFileSize
new12.36 KB

My understanding is that Drush 2.0 add-ins are not modules at all. Just ignore the fact that they appear in admin/build/modules. They have .module and .info files so that they can be placed in /module directories without issue. Disable them if you've enabled them.

I was able to get this working by applying the above patch and then tinkering with some of the function naming. I can't recall exactly what I did, thus I've including the whole directory. I've got it in /sites/all/modules and drush 2.0 can see it and will execute the commands from it. The help text doesn't work, though I don't know if that's a Drush problem or specifically with this add-in.

Andrew Schulman’s picture

Subscribing

Macronomicus’s picture

@chiddicks
Thanks for the code .. I will try it out!

Yeah I figured it wasn't right to be enabled and uninstalled my bits when it wasn't working.
I dont think I can go back to drush 1.0 for this module ... since drush works wonderfully as it is.
I like 2.0 and wish the mm was included in it. Maybe they have good reasons .. I cant recall but I think I read something about issues with enabling dependencies. I dunno

I cant wait to try out your remake of the code to see if it works. Thanks!

socialnicheguru’s picture

i am using it. so far so good. It is great. especially since I don't have to enable a module.

I use mm uninstall to try and find modules that have created problems in my system and it works well.

THANKS!

ericm’s picture

subscribing

clemens.tolboom’s picture

Assigned: Unassigned » clemens.tolboom
Priority: Normal » Critical

As drush-6.x-1.4 is no longer available drush_mm should asap be ported :(

clemens.tolboom’s picture

Status: Needs work » Fixed

This is fixed. Thanks for the hints.

I still don't like the changes done with drush-2.x. afaik an update of drush_mm is not notified because you don't need to enable drush_mm anymore. Can someone confirm this please?

chiddicks’s picture

I believe you are correct; since you do not have to enable the module you would not be notified if drush_mm was updated. However, since the drush_mm.module is an empty file, there's no harm in enabling it, and presumably you would be notified when it is updated.

Andrew Schulman’s picture

I still don't like the changes done with drush-2.x. afaik an update of drush_mm is not notified because you don't need to enable drush_mm anymore.

I agree, and it's worse with drush itself, since it can't be installed as a module any more. (Couldn't resist commenting although it's OT here.)

Andrew Schulman’s picture

Status: Fixed » Active

I'm sorry, but I just installed drush_mm 6.x-1.2, and I can't see that's it's working at all. drush doesn't report any of the mm commands, and I'm not able to enable it at admin/build/modules, since it still depends on the drush module, which isn't present. Thanks, Andrew.

chiddicks’s picture

To build on my previous comment, the dependency on Drush should be removed from drush_mm, since Drush is now a standalone piece of code and can exist anywhere.

clemens.tolboom, could you create a new drush_mm-6.x-2.0 release with the code I posted earlier? That corresponds with the Drush 2.x naming scheme. Presumably the reason drush_mm 6.x-1.2 is not working for you andrex593 is that it's still the Drush 1.x version of the module.

clemens.tolboom’s picture

Version: 6.x-1.1 » 6.x-2.x-dev
Status: Active » Fixed

Sorry for the confusion. When I submitted the 2.x version there was no way of enabling and advising to use the 2.x version ... the package had to be build first.

And I release a 1.2 because I branched of from that version.

So everything is now in place and all my users will complain about the lack of support for the 1.2 release :(

Status: Fixed » Closed (fixed)

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