-
Notifications
You must be signed in to change notification settings - Fork 14
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
Handle multisites and site aliases #68
Merged
arnested
merged 80 commits into
arnested:feature/site-alias
from
joddie:feature/site-alias
Apr 20, 2016
Merged
Handle multisites and site aliases #68
arnested
merged 80 commits into
arnested:feature/site-alias
from
joddie:feature/site-alias
Apr 20, 2016
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Properly chain into the checker chain for js/css modes. Also check info files. Closes arnested#41.
Add menu items for function & hook templates
Add interface with gtags via `ggtags.el'
Use flycheck-add-next-checker.
No need to call `cd-absolute`. It's probably better to supply the DRUPAL_ROOT as a parameter to drush.
Added the DRUPAL_ROOT as parameter to the drush command.
Evaluate active region with `drush php-eval`. Idea from @kostajh. Closes arnested#46.
drupal-detect-drupal-version: Allow tabs in .info
Minor glitch in on of the improved regexps from arnested#50.
When inserting a hook_update_N() with `drupal-insert-hook` an we will suggest an ID the hook implementation based on previous update hooks and Drupal and module major versions.
The Drupalize.Me API site is retired. See https://drupalize.me/api-site.
Flycheck updates
Fix up for latest flycheck.
With eldoc enabled, this function could move point unexpectedly to the end of line when point was on the *definition* of anything listed in the TAGS file. (This is due to the `find-tag-noselect`, which can return the already-open buffer for a given tag's file, if one exists). Adding a `save-excursion` around the `with-current-buffer` fixes this bug.
Fix/etags moves point
The hook implementation skeleton funcalls `drupal-get-function-args` to check whether the new function implementation already exists elsewhere in the project. When the value of this variable is `drupal/etags-get-function-args`, it throws an error for non-existent function names, making it impossible to insert a new implementation. Adding `ignore-errors` around the call fixes this.
Avoid "no tags containing" error in hook skeleton
Add `drupal-drush-sql-cli` command
…tibility Also load gtags.el with helm-gtags.
It is slow and requires another version of makeinfo.
- New variable: `drupal-drush-site-url`, allows specifying a site to work on within a multisite configuration - New command: `drupal-set-site` allows interactively changing the site or site alias to work on - New function: `drupal-call-drush-process` abstracts calling drush with the correct options, including site alias or URI if set - New function: `drupal-drush-command-to-string` runs a drush command and return its output as a string
Additionally, make both automatically buffer-local, like drupal-{project,version}, etc.
- New function `drupal-dir-site-aliases` returns a list of site aliases matching a given directory - Use the new function in `drupal-set-site` to offer only aliases that match the current context as choices
Without this fix, the dynamic mode-line indicator from commit 4188199 is displayed in two separate pieces, and raises an error on being clicked (`Cannot find minor mode ...`). Using `concat` in the mode-line expression restores the expected clickable behavior.
This looks very impressive, @joddie! I'll try it out the next couple of days and provide some feedback! |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This pull request is based on the work in #18 to make drush commands support site aliases. It also allows drupal-mode to work better with multisite installations. (I dislike multisite setups, but sometimes have to deal with them…)
It adds a concept of the "current site", which can be specified either using a site alias or a parameter to
--uri
. It also refactors all Drush calls so that they go through a standard interface which respects these parameters.The "current site" setting is common to all buffers within the same project. It should be detected automatically, and can be changed using a command (
M-x drupal-set-site
) or via the menubar.This has received only light testing, but it seems to work, so I wanted to open a PR to allow others to potentially test and review it. (Also happy to add more ERT tests, etc.)