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

fix(scoop-alias): Pass options correctly #6003

Merged
merged 3 commits into from
Jul 15, 2024

Conversation

lewis-yeung
Copy link
Contributor

@lewis-yeung lewis-yeung commented Jun 5, 2024

Description

This PR has fixed a bug that the option -v/--verbose cannot be passed to the command scoop alias list.

Motivation and Context

Closes #5767.

How Has This Been Tested?

Suppose we have an alias with Summary properly set, run:

scoop alias list -v | Format-List # the property `Summary` is showed
scoop alias list | Format-List # the property `Summary` is not showed

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.

@mattcargile
Copy link
Contributor

Nice. This looks like it fixes my issue.
#5767

lib/alias.ps1 Outdated Show resolved Hide resolved
lib/alias.ps1 Outdated Show resolved Hide resolved
lib/alias.ps1 Outdated Show resolved Hide resolved
@niheaven
Copy link
Member

niheaven commented Jul 12, 2024

There're some bugs in the code, and I push some tweaks:

  • Move alias-related code to lib/commands.ps1
  • Pipe string into Out-UTF8File()
  • Remove get_aliases_from_config() and use get_config() directly
  • Drop depends on lib/install.ps1
  • Compatible with Windows PowerShell

@niheaven niheaven merged commit 0138dc4 into ScoopInstaller:develop Jul 15, 2024
2 checks passed
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.

3 participants