Skip to content

Commit

Permalink
(GH-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.
ferventcoder committed Jan 30, 2016

Verified

This commit was signed with the committer’s verified signature.
Eliulm Elias Wahl
1 parent b27204a commit aba98df
Showing 1 changed file with 5 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -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 aba98df

Please sign in to comment.