Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mark Chocolatey shims (chocolatey. cinst, clist, cpush, cuninst, cup) as deprecated #2641

Closed
gep13 opened this issue Mar 10, 2022 · 5 comments · Fixed by #2643
Closed

Mark Chocolatey shims (chocolatey. cinst, clist, cpush, cuninst, cup) as deprecated #2641

gep13 opened this issue Mar 10, 2022 · 5 comments · Fixed by #2643

Comments

@gep13
Copy link
Member

gep13 commented Mar 10, 2022

Going forward, usage of the shimmed versions of choco commands is not recommended.

i.e. rather than using clist the recommendation is to use choco list

This is true for all shims/commands:

  • chocolatey
  • cinst
  • clist
  • cpush
  • cuninst
  • cup

Documentation on the site and help documentation should be updated to remove mention of these shims, and any mention of them in the usage sections of help commands should be marked as deprecated.

In addition, the generatedocs.ps1 file should be updated to add a warning message to the top of each command page, indicating that the shim will be removed in 2.0.0.

@gep13
Copy link
Member Author

gep13 commented Mar 10, 2022

A follow up issue has been created here: #2642 in the 2.0.0 milestone to completely remove these shims.

@gep13 gep13 changed the title Mark Chocolatey shims (chocolatey. clist, cpush, cuninst, cup) are deprecated Mark Chocolatey shims (chocolatey. cinst, clist, cpush, cuninst, cup) are deprecated Mar 10, 2022
AdmiringWorm added a commit to AdmiringWorm/choco that referenced this issue Mar 10, 2022
This commit updates the help text for relevant commands
to mention that their shims will be removed in v2.0.0
AdmiringWorm added a commit to AdmiringWorm/choco that referenced this issue Mar 10, 2022
This commit updates the generate docs helper to add
a global warning for all commands mentioning that shims
will be removed in v2.0.0. It also mentions which shims will
be removed, and their full use.
gep13 added a commit to AdmiringWorm/choco that referenced this issue Mar 10, 2022
gep13 added a commit that referenced this issue Mar 10, 2022
…-chocolatey-cinst-clist-cpush-cuninst-cup-are-deprecated

(#2641) Add deprecation messages for shims
@gep13 gep13 added 4 - Done and removed 3 - Review labels Mar 10, 2022
@gep13 gep13 changed the title Mark Chocolatey shims (chocolatey. cinst, clist, cpush, cuninst, cup) are deprecated Mark Chocolatey shims (chocolatey. cinst, clist, cpush, cuninst, cup) as deprecated Mar 18, 2022
gep13 added a commit that referenced this issue Mar 18, 2022
* release/1.0.0: (65 commits)
  (version) v1.0.0
  (#2443) Fix misspellings for profile text
  (#2468) Remove choco update command
  (#2468) Remove choco version command
  (#2602) Add 1.0.0 of shimgen and update shims
  (#89) Remove cpack shims on package upgrades
  (#89) Remove cpack shim for choco pack
  (maint) Update deprecation notice for config settings
  (build) Additional tweaks to version numbers
  (build) Add SolutionVersion.cs file to artifacts
  (docs) Update committers docs with correct/fixed links
  (build) Minor tweaks to build files
  (#2615) Reference CREDITS file for other licenses
  (build) Refactor Nuget Upload
  (build) Added missing Kotlin import
  (maint) Whitespace
  (#2614) Update 7zip / Shimgen licenses
  (#2614) Update project  contributors
  (#2641) Minor tweaks to wording and formatting
  (#2462) Remove mention of alias for search comand
  ...
@sebma
Copy link

sebma commented Aug 8, 2022

@gep13 Hi,

Is it wrong for us chocolatey users to use those shims ?

Isn't it easier to type cup than to type choco upgrade ?

What are the reasons you want to remove those shims ?

Do you plan to replace those shims by new shims in the near future ?

@pauby
Copy link
Member

pauby commented Aug 10, 2022

@sebma

What are the reasons you want to remove those shims ?

There are various reasons to remove the shims but it is generally due to clashes with other software for some of those. Rather than have some shims and remove others we decided to remove them all.

Is it wrong for us chocolatey users to use those shims ?

Nothing wrong with using them if you are aware of the consequences (they won't work natively in Chocolatey CLI in future versions and they could clash with other software that you have installed).

Isn't it easier to type cup than to type choco upgrade ?

It is. But troubleshooting issues caused is problematic. If you want to keep using them, add them as PowerShell (or your shell of choice) aliases.

Do you plan to replace those shims by new shims in the near future ?

No. If you want to keep using the aliases after they have been removed, use PowerShell (or your shell of choice) aliases.

@sebma
Copy link

sebma commented Aug 10, 2022

@pauby Hi,
First let me thank you for your answer.

I have some last questions 😄 .

You said :

they could clash with other software

Do you know which software could clash with those chocolatey shims ?

No. If you want to keep using the aliases after they have been removed, use PowerShell (or your shell of choice) aliases.

If I create powershell aliases (or functions), wouldn't they clash with the other software you're talking about ?

If another software ever creates a command called choco, will you also remove or rename the choco command ?

@pauby
Copy link
Member

pauby commented Aug 10, 2022

Do you know which software could clash with those chocolatey shims ?

cpack was one clashing with the cmake software (from memory).

If I create powershell aliases (or functions), wouldn't they clash with the other software you're talking about ?

Absolutely. That decision would be yours though - if you have the software you wouldn't add those aliases.

If another software ever creates a command called choco, will you also remove or rename the choco command ?

No. choco is well established as a command.

This is a closed issue so lets leave the discussion here.. If you need to discuss this any further, Discord would be the best place.

@chocolatey chocolatey locked as resolved and limited conversation to collaborators Aug 10, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants