-
Notifications
You must be signed in to change notification settings - Fork 29
Improve how kalatheme detects if modules and libararies paths are writeable #204
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
the subtheme should write to sites/all/themes generally – that said we assume. but I am guessing that https://api.drupal.org/api/drupal/includes%21file.inc/function/drupal_realpath/7 |
Regardless of that, my query is more about why we're checking the |
Writing to a subtheme directory seems strange too. The Libraries module has libraries_get_path(), which can be a nice wrapper around the path/library discovery. We could transition from having our custom implementation to using something like that. |
Looks like part of that is to update KalaTheme itself, which seems like it would be something for either Drush, or Update module to take on. Any reason for this to be there at all? |
@RobLoach KT has to be able to write to the themes dir in order to generate a sub theme. Are you suggesting this is insecure as well? I haven't really explored the drush integration in KT but the functionality to generate a sub theme exists in the config. I don't have experience with the implementing the update module—are we able to get around any security implications by using it? |
I too am confused why we are checking I have updated the issue description to better reflect our goals. To address some other notions raised here: @soniktrooth is correct we cannot use the Drush subtheme generation is already possible: We already require Libraries It is pretty amazing that within a single theme so much is possible without other helper modules or themes. Zen had https://www.drupal.org/project/zenophile and Omega https://www.drupal.org/project/omega_tools but recent versions of these themes now only support Drush to generate subthemes. The subtheme UI generator is a pretty big differentiator, and something we should retain, even if the implementation needs to be a bit hacky in the end. |
I'm on board with switching to using |
So i think
WRT NOTE: subthemes can also potentially be dropped in an installation profile. @soniktrooth i hope that helps a bit. |
This does help @pirog—thanks. You are right about I think we should do the following: rename
|
@soniktrooth these all seem like very solid improvements! |
#204 Removing kalatheme_lib_dir() and better comments for kalatheme_h…
fix was merged. Closing. |
While looking into #123 I came across kalatheme_has_write_access() and kalatheme_lib_dir()
These functions seem a little fuzzy to me and I have questions for @pirog or anyone who knows better.
Why do we ever need to check if the modules dir is writable? What are we writing to the modules dir and why? My understanding was that if your module's dir is writable you got some serious security problems...
Seems a little hard coded and sledge hammery to me. Panopoly includes the libraries module which can tell us where the libraries dir is. At worst it's probably a site var anyway. Is there a reason we're not doing that?
The text was updated successfully, but these errors were encountered: