Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Trying to install Sub-Theme using Drush, getting this error message...
Command omega-wizard needs the following module(s) enabled to run: omega. [error]
The drush command 'omega-wizard' could not be executed. [error]
Comments
Comment #1
steven_kropp CreditAttribution: steven_kropp commentedNevermind... Solved...
I had originally installed Omega Tools, I had uninstalled it and cleared the cache of the website, yet it still wasn't working.
Then I cleared my Drush cache and that fixed the issue.
Comment #2
fubhy CreditAttribution: fubhy commentedComment #4
Pere OrgaThe issue still happens. The solution is to clear the cache after enabling Omega.
Comment #5
fubhy CreditAttribution: fubhy commentedYou don't have to 'enable' omega or anything. Just place 'omega' in your themes folder. If you had omega tools previously, run "drush cc drush". If not, it should work right away... If it doesn't, run "drush cc drush" just for good measure and try again - Should work now.
Comment #6
Pere OrgaThanks
So the cache has to be cleared after downloading and placing Omega in the themes directory.
This is reproducible in a clean install.
Comment #7
charlie charles CreditAttribution: charlie charles commentedI had the same problem as steven_kropp
this should be included in the manual
to clear cache before making a sub theme
Comment #8
fubhy CreditAttribution: fubhy commentedPlease do so! Anyone can edit the handbook pages! :)
Comment #9
charlie charles CreditAttribution: charlie charles commentedThanks, I just tried to up date the docs
but I get this message
Comment #10
Pere OrgaSorry I did it first. But feel free to improve it.
Comment #11
charlie charles CreditAttribution: charlie charles commentedThank you netol
Comment #12
fubhy CreditAttribution: fubhy commentedthanks you two.
Comment #13
luco CreditAttribution: luco commentedafter some hours pulling my hair out, I stumbled across something that might help: you actually have to make Omega your default theme for this to work.
Comment #14
steinmb CreditAttribution: steinmb as a volunteer commentedGot my too. The commands get listed by crush but they simply do work. Should not need to be this way. In Drupal 7 is every theme present loaded/found by drupal, enabled or not. This is changed in D8 where no other then the enabled themes are included. Oh, well.
Comment #15
karolus CreditAttribution: karolus as a volunteer commentedI"m experiencing the same issue after upgrading to the latest version of Acquia Dev Desktop. This also applies to the command $ drush omega-export.
Of course, the first thing I did was clear all caches, but it doesn't help.
Omega is already installed in the sites/all/themes folder, and is the current version. Like luco found out in issue #13, the v.4.4 base theme needs to be enabled for this to work. Once I did this, I could do it. Setting my subtheme as default reverted back to the same problems as before.
I'm on a project deadline, but will be back on this in the next few days, if a solution hasn't been found by then. Based on what was changed in the Dev Desktop update, the main thing to check is probably compatibility with the latest version of Drush.
Additional Info 1:
I checked on another site I'm working on, but haven't upgraded that install of Omega. Same error when running $ drush omega-export
Additional Info 2:
To be sure no other issues were present, I quit Acquia Dev Desktop and restarted, then installed a clean build of Drupal core 7.38, and set up. Once done, the following commands were run:
$ drush dl omega (ran OK)
$ drush en omega (ran OK)
$ drush omega-wizard (error below)
Additional Info 3:
To confirm that it's an interaction with Drush, I rolled back my install of Acquia Dev Desktop to the 2015-04-03 build (running Drush 7.0.0-rc1). Once this was done, all Omega commands worked fine. Apparently, there's some interaction with Drush 8.0.x (the current version of Dev Desktop is the 2015-07-27 build). I'm figuring there's a compatibility issue between Omega 4.x and Drush 8.0.x at this point.
Comment #16
Rade CreditAttribution: Rade commentedI ran into the same problem. A temporary work-around is to set Omega as the default theme (instead of your sub-theme) and then the drush commands work.
Comment #17
SeteboS CreditAttribution: SeteboS commentedis there any update on this?
same issue.. omega drush commands are working when omega is the default theme but not if a subtheme is set as default
UPDATE: downgraded to drush 7 from 8-dev and there is no issue.
Comment #18
fubhy CreditAttribution: fubhy commentedThis is a drush issue (not sure when or why it was changed). Please open a bug report / regression report on the github issue page for drush!
Comment #19
discipolo CreditAttribution: discipolo commentedhttps://github.com/drush-ops/drush/issues/1575
Comment #20
C13L0 CreditAttribution: C13L0 as a volunteer commentedIn order to use the Omega 4 drush commands, you will need to switch your drush version.
Switch version to drush 7
$
cd .composer/vendor/drush/drush
$
git checkout remotes/origin/7.x
$
drush cc drush
<--very important!You will now be able to run the command: $ drush omega-wizard
Changing drush version also works to export your theme.info file: $ drush omega-export themename --revert
To switch back to master (drush 8)
$
cd .composer/vendor/drush/drush
$
git checkout master
$
drush cc drush
<--very important!Comment #21
steinmb CreditAttribution: steinmb as a volunteer commentedComment #23
ayushmanshrestha CreditAttribution: ayushmanshrestha commentedI tried setup omega-8.x-5.0-alpha3 via drush but not working.
here is the sequence i tired;
$ drush --version
Drush Version : 8.0.0-rc4
$ drush dl omega-8.x-5.0-alpha3
Project omega (8.x-5.0-alpha3) downloaded to [success]
/var/www/html/biolab//themes/omega.
Project omega contains 2 themes: omega, omega_starterkit.
$ drush cc drush
'drush' cache was cleared. [success]
drush omega-wizard
The drush command 'omega-wizard' could not be found. Run `drush [error]
cache-clear drush` to clear the commandfile cache if you have
installed new extensions.
What could be the solution? already tired "drush cc drush".
Comment #24
steinmb CreditAttribution: steinmb as a volunteer commented@ayushmanshrestha I do not think omega-8.x-5 have a working wizard. Anyway, you have to make sure to enable Omega theme and set it as default before running. Still having problem, please open a new issue. Posting in old closed issues is normally not a good idea.
Comment #25
erok415 CreditAttribution: erok415 as a volunteer commentedI've created sub-themes of Omega countless times and I always seem to forget to set Omega as the default theme. Thanks #13 @luco for the reminder. I keep saying "doi!" to myself. I thought it was because I was using Acquia DevDesktop and the default version of Drush was 8.x. Ugh! ...and just in case you ever try to override Acquia DD's Drush install and try to install your own version of Drush with composer....good luck. Modifying both ~/.bashrc and ~/.bash_profile didn't help.
E
Comment #26
DuaelFrI reopened an issue on drush because having to downgrade it or to set omega as the default theme is not always an option
https://github.com/drush-ops/drush/issues/1878
Comment #27
mel-miller CreditAttribution: mel-miller commentedI'm still having a problem even when I revert to Drush 7, and enable Omega as the default theme. Thoughts?
Comment #28
rajmataj CreditAttribution: rajmataj commentedI'm using Drush 8.1 and found this worked for me for Omega 7.x-4.4 on a fresh Drupal 7.50 install:
I don't have Drush 7 on my machine (scotchbox) so I didn't need to switch to anything. I had installed Drush 8 with Composer. Hopefully this helps others.
Comment #29
ann b CreditAttribution: ann b commentedYes, the Omega base theme needs to be enabled in order for the omega-xxxxx commands to work. It does not have to be set to the default theme. Thank you @DuaelFr for your work on this drush issue.
Comment #30
stefan93 CreditAttribution: stefan93 commentedHas @Rade says enable omega and set it bay defauft works fine for me.
tanks Rade