From 8474faec8da7e8cf02905e1850b0b27f13ea1000 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Oskar=20Sch=C3=B6ldstr=C3=B6m?= Date: Fri, 24 Mar 2017 20:43:01 -0500 Subject: [PATCH] Support forks or custom vendor directory with vendor_path option --- Vagrantfile | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/Vagrantfile b/Vagrantfile index 1a9850fa4..a9e1ecd54 100644 --- a/Vagrantfile +++ b/Vagrantfile @@ -46,9 +46,10 @@ if File.exist?("#{host_project_dir}/composer.json") end # If Drupal VM is a Composer dependency set the correct path. - if Dir.exist?("#{host_project_dir}/vendor/geerlingguy/drupal-vm") - host_drupalvm_dir = "#{host_project_dir}/vendor/geerlingguy/drupal-vm" - guest_drupalvm_dir = "#{guest_project_dir}/vendor/geerlingguy/drupal-vm" + vendor_path = cconfig['vendor_path'] || 'vendor/geerlingguy/drupal-vm' + if Dir.exist?("#{host_project_dir}/#{vendor_path}") + host_drupalvm_dir = "#{host_project_dir}/#{vendor_path}" + guest_drupalvm_dir = "#{guest_project_dir}/#{vendor_path}" end # Read config_dir from composer.json if set.