Skip to content

Commit

Permalink
(chocolateyGH-584) Hook for loading licensed posh extensions
Browse files Browse the repository at this point in the history
If the license is valid, provide a hook for loading the posh
extensions. They will check on the license themselves and fail hard, so
it is best to provide this hook so that choco will continue to work
with only warnings if the license expires and the user hasn't done
anything.
  • Loading branch information
ferventcoder committed Jan 28, 2016
1 parent 65e6df3 commit 3390867
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -410,6 +410,11 @@ public static void set_environment_variables(ChocolateyConfiguration config)
Environment.SetEnvironmentVariable("https_proxy", "{0}{1}".format_with(proxyCreds, config.Proxy.Location));
Environment.SetEnvironmentVariable("chocolateyProxyLocation", config.Proxy.Location);
}

if (config.Information.LicenseIsValid)
{
Environment.SetEnvironmentVariable("ChocolateyLicenseValid", "true");
}
}
}
}

0 comments on commit 3390867

Please sign in to comment.