-
Notifications
You must be signed in to change notification settings - Fork 70
Conversation
composer.json
Outdated
"post-install-cmd": [], | ||
"post-update-cmd": [] | ||
"post-install-cmd": [ | ||
"drush emulsify" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove
composer.json
Outdated
"repositories": {}, | ||
"require": { | ||
"drupal/components": "^1.0", | ||
"drupal-pattern-lab/unified-twig-extensions": "dev-develop" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can this be on drupal.org?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sounds like it will be on Packagist
ee35256
to
333cdd2
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is awesome - I left one comment because it failed inside of my older Drupal install.
# Link contrib twig functions into the components directory | ||
|
||
# First we need to find out whether this is inside a Drupal install or standalone Emulsify | ||
if [ -d ../../../../vendor ] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have an older Drupal install that I ran this inside of and it didn't have the /web directory. Should we make this more open-ended to handle that?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This seems good to me following our conversation. Once you add the updates to the readme,
README.md
Outdated
1. `composer require fourkitchens/emulsify` | ||
2. `cd web/themes/contrib/emulsify/` | ||
3. `npm install` or `yarn install` | ||
4. Optional (but recommeded): Create "child" theme `drush emulsify "Theme Name"` (more details below) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
*recommended
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also, is it drush emulsify "Theme Name"
or drush emulsify site_machine_name
This PR does the following:
composer install
yarn install
(ornpm install
)To Review:
If installing Emulsify standalone:
composer install
inside it, or just runcomposer create-project "fourkitchens/emulsify:dev-composer-installable" --stability dev --no-interaction emulsify
yarn upgrade && yarn install && yarn start
components/_twig-components/functions
If installing inside a Drupal instance:
composer require "fourkitchens/emulsify:dev-composer-installable"
cd web/themes/contrib/emulsify/
yarn upgrade && yarn install && yarn start
components/_twig-components/functions
Todo:
The child theme needs to get these components as well. Maybe a symlink from the child themesfunctions
folder to the one in Emulsify'svendor
directory? (Maybe emulsify should just use a symlink too, instead of copying the file.)(I think as long as the package.json is copied, along with the
scripts
folder, the child theme will get the functions in place.)The functions are placed in the root vendor directory, notemulsify/vendor
when installed in a Drupal instance... What do we do?(I created a script to check for the vendor directories, so it'll work in both cases)
scripts
directory for both regular and --slim