(MODULES-3228) Use PSGallery Tags on DSC Resources
(MODULES-3228) Use PSGallery Tags on DSC Resources

Each submodule tracks on a commit SHA1, but that SHA1 doesn't
necessarily correspond or represent an actual release of that
submodule (aka DSC Resource) to the PowerShell Gallery. However,
those resources are tagged when they are released to the gallery
with *-PSGallery, where * represents the version going up to the
gallery. This allows someone to find the currently released
version of a module/DSC Resource.

Instead of trusting the tags that are available for a resource in
the list of submodules, which tends to be completely inaccurate if
you are looking for the latest release, gather all PSGallery tags
and find the latest version. Then check that version out for
building the resource.

This code is similar to what James proposed in de5a10eac0.

Paired with James Pogran <james.pogran@puppet.com>

ConclusionMC/puppetlabs-dsc,ConclusionMC/puppetlabs-dsc,ferventcoder/puppetlabs-dsc,Iristyle/puppetlabs-dsc,puppetlabs/puppetlabs-dsc,ConclusionMC/puppetlabs-dsc,ferventcoder/puppetlabs-dsc,jpogran/puppetlabs-dsc,Iristyle/puppetlabs-dsc,ConclusionMC/puppetlabs-dsc,Iristyle/puppetlabs-dsc,puppetlabs/puppetlabs-dsc,ConclusionMC/puppetlabs-dsc,puppetlabs/puppetlabs-dsc,ferventcoder/puppetlabs-dsc,jpogran/puppetlabs-dsc,jpogran/puppetlabs-dsc,ferventcoder/puppetlabs-dsc,Iristyle/puppetlabs-dsc