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

feat(scoop-hold,scoop-unhold): Support -g/--global flag #4991

Merged
merged 2 commits into from
Jun 17, 2022

Conversation

lewis-yeung
Copy link
Contributor

Description

Support a -g/--global flag for scoop hold/scoop unhold, which tells Scoop to hold/unhold globally installed apps.

Motivation and Context

Closes #4990.

How Has This Been Tested?

  1. Install an app both user-scoped and globally: scoop install <app> and scoop install -g <app>.

  2. Hold/unhold the user-scoped app: scoop hold <app>/scoop unhold <app>. This does not require admin privileges.

  3. Hold/unhold the global app without admin privileges: scoop hold -g <app>/scoop unhold -g <app>. It shows an error:

    ERROR You need admin rights to hold a global app.
    ERROR You need admin rights to unhold a global app.
    
  4. Hold/unhold the global app with admin privileges: sudo scoop hold -g <app>/sudo scoop unhold -g <app>. It works as expected. (Assuming that sudo has been installed properly.)

Checklist:

  • I have read the Contributing Guide.
  • I have ensured that I am targeting the develop branch.
  • I have updated the documentation accordingly.
  • I have updated the tests accordingly.
  • I have added an entry in the CHANGELOG.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants