choco icon indicating copy to clipboard operation
choco copied to clipboard

Add support for license packages.

Open TheCakeIsNaOH opened this issue 2 years ago • 2 comments

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.

TheCakeIsNaOH avatar Dec 03 '21 16:12 TheCakeIsNaOH

🤔 What about a choco license command?

Some things you could possibly do with it:

  1. 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
  2. choco license list - Get information about the currently installed license (name, license count, license type, expiration, etc.)
  3. choco license pack - Generate a chocolatey-license (or chocolatey.license package) that includes scripts to install the license.
  4. choco license uninstall - I imagine this would just remove the license file 🤷

corbob avatar Sep 02 '22 19:09 corbob

🤔 What about a choco license command?

Some things you could possibly do with it:

  1. 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

  2. choco license list - Get information about the currently installed license (name, license count, license type, expiration, etc.)

  3. choco license pack - Generate a chocolatey-license (or chocolatey.license package) that includes scripts to install the license.

  4. choco license uninstall - I imagine this would just remove the license file 🤷

Related to: https://github.com/chocolatey/choco/issues/2829

mkevenaar avatar Sep 02 '22 20:09 mkevenaar

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.

TheCakeIsNaOH avatar Nov 18 '22 05:11 TheCakeIsNaOH