choco
choco copied to clipboard
Add support for license packages.
After some discussion with @gep13 on future plans for non-windows systems, it may make sense to create a new type of package, specifically for licenses (for licensed Chocolatey editions). Basically a .license
equivalent to .extension
package.
So for any package ID ending in .license
, choco would check for a chocolatey.license.xml
in a license
directory, and copy it to $env:chocolateyinstall\license\chocolatey.license.xml
. I suppose it probably should also check for chocolatey.license.xml.txt
as well. Uninstall may be a bit more tricky, since what if you have multiple different .license
package IDs installed? Maybe record what is the most recent license copy is?
With this in place, the package builder probably could be updated to work with this type of package, so license packages could be created automatically just by passing license file.
🤔 What about a choco license
command?
Some things you could possibly do with it:
-
choco license install ./path/to/file.extension
- This could read in the file specified, verify it's a valid license, then create the appropriate directory structure and name it correctly -
choco license list
- Get information about the currently installed license (name, license count, license type, expiration, etc.) -
choco license pack
- Generate achocolatey-license
(orchocolatey.license
package) that includes scripts to install the license. -
choco license uninstall
- I imagine this would just remove the license file 🤷
🤔 What about a
choco license
command?Some things you could possibly do with it:
choco license install ./path/to/file.extension
- This could read in the file specified, verify it's a valid license, then create the appropriate directory structure and name it correctly
choco license list
- Get information about the currently installed license (name, license count, license type, expiration, etc.)
choco license pack
- Generate achocolatey-license
(orchocolatey.license
package) that includes scripts to install the license.
choco license uninstall
- I imagine this would just remove the license file 🤷
Related to: https://github.com/chocolatey/choco/issues/2829
Since the license
command is going to be added (#2829), I think this can be closed, since the license installation functionality can be added there.