tamagokun / pomander-wordpress

Wordpress tasks for use with Pomander
http://ripeworks.com/pomander/wordpress.html
MIT License
36 stars 5 forks source link

Improve Wordpress directory support #15

Closed Danielpk closed 10 years ago

Danielpk commented 10 years ago

First of all, i dont think it is ready to merge, let discuss the possibility.

I added a new option at wordpress env configuration: wp_own_directory, wp_lang, wp_debug

wp_lang and wp_debug are self explanatory.

When wp_own_directory is set to true it will make a custom configuration at wp-config.php to allow access blog under root project folder. This eliminates the need of Virtual Host to wordpress folder and eliminate the public symlink. More information at: http://codex.wordpress.org/Giving_WordPress_Its_Own_Directory It help me to configure project under subfolder.

So what you think?

Ps.: Sorry for my grammar. :baby:

tamagokun commented 10 years ago

I like this. I've been meaning to really improve the deploy:wordpress task a whole bunch, so I can refine it to allow Wordpress project in the project root. If you don't mind, i'd like to tackle it, but would love a pull request for the inclusion of wp_lang and wp_debug as those are certainly important settings.

tamagokun commented 10 years ago

I think the better option here would be to have an option called install_dir that lives in the wordpress settings array.

Doing something like this you could allow people to install wordpress in the root dir, or in any dir they please.

The defaults would be:

$env->wordpress(array(
  'install_dir' => './wordpress'
));

so you could change it to:

$env->wordpress(array(
  'install_dir' => './'
));

How's that?

tamagokun commented 10 years ago

These should all be included now.

There are a significant amount of options available for wp-config as well as being able to specify your install dir relative to the project root.

Thanks for thePR!