maestrodev / librarian-puppet

Since 0.9.11.6 this fork is no longer used
MIT License
16 stars 7 forks source link

Add Modulefile of modules for git repository under subdirectories #3

Closed bltavares closed 11 years ago

bltavares commented 11 years ago

Make git repositories with puppet modules under a subdirectory contribute to the dependency resolution

Some times the git repository contains a group of modules as subdirectories. One example is https://github.com/example42/puppet-modules

When it happens, the Modulefile for the project specified is not being picked up, and their dependencies are not resolving. This is a feature supported by Librarian.

This pull request is addressing this issue.

To make it easier to check the error, I created a repo with a module as a subdirectory.

Then use this Puppetfile:

forge "http://forge.puppetlabs.com"

mod 'apt-avahi',
    :git => 'https://bitbucket.org/bltavares/example-puppet-modulefile-subdir.git',
    :path => 'apt-avahi'

Before applying the patch, you will find this dir structure under modules:

% ls modules
apt-avahi

After applying the patch, the modules dir will contain the resolved modules:

% ls modules
apt       apt-avahi avahi     stdlib
bltavares commented 11 years ago

Sorry, I sent it to the wrong repo. Feel free to reject it.