-
Notifications
You must be signed in to change notification settings - Fork 123
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
Added fixes to better support packages with multiple origins and multiple executables #170
Conversation
bfb781d
to
11d701e
Compare
406b5a7
to
11d6aa4
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fantastic PR @acecilia! 👏
…rt when a package with the same name is installed from different origins (for example: yonaskolb/xcodegen and acecilia/xcodegen). [yonaskolb#170](yonaskolb#170) @acecilia - Rewrite the `list` option, to better support when a package produces multiple executables. [yonaskolb#170](yonaskolb#170) @acecilia - Rewrite and fix the `uninstall` option: previously, the name for the symlink to remove was calculated using the package name passed from command line, which could be partial (for example `simple` instead of `simplepackage`), resulting on the symlink not being removed. [yonaskolb#170](yonaskolb#170) @acecilia
11d6aa4
to
aa990eb
Compare
…rt when a package with the same name is installed from different origins (for example: yonaskolb/xcodegen and acecilia/xcodegen). [yonaskolb#170](yonaskolb#170) @acecilia - Rewrite the `list` option, to better support when a package produces multiple executables. [yonaskolb#170](yonaskolb#170) @acecilia - Rewrite and fix the `uninstall` option: previously, the name for the symlink to remove was calculated using the package name passed from command line, which could be partial (for example `simple` instead of `simplepackage`), resulting on the symlink not being removed. [yonaskolb#170](yonaskolb#170) @acecilia
aa990eb
to
34dda21
Compare
…rt when a package with the same name is installed from different origins (for example: yonaskolb/xcodegen and acecilia/xcodegen). [yonaskolb#170](yonaskolb#170) @acecilia - Rewrite the `list` option, to better support when a package produces multiple executables. [yonaskolb#170](yonaskolb#170) @acecilia - Rewrite and fix the `uninstall` option: previously, the name for the symlink to remove was calculated using the package name passed from command line, which could be partial (for example `simple` instead of `simplepackage`), resulting on the symlink not being removed. [yonaskolb#170](yonaskolb#170) @acecilia
34dda21
to
2f4b8f6
Compare
XCTAssertEqual(cache.list, """ | ||
SimplePackage (https://github.com/yonaskolb/SimplePackage.git) | ||
- 4.0.0 | ||
SimplePackage (https://github.com/acecilia/SimplePackage.git) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If you have other account you prefer to rely on, instead of mine, I can change this
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Totally fine, if it sticks around 👍
…rt when a package with the same name is installed from different origins (for example: yonaskolb/xcodegen and acecilia/xcodegen). [#170](yonaskolb/Mint#170) @acecilia (#170) - Rewrite the `list` option, to better support when a package produces multiple executables. [#170](yonaskolb/Mint#170) @acecilia - Rewrite and fix the `uninstall` option: previously, the name for the symlink to remove was calculated using the package name passed from command line, which could be partial (for example `simple` instead of `simplepackage`), resulting on the symlink not being removed. [#170](yonaskolb/Mint#170) @acecilia
Added fixes to cover the following two scenarios:
1- When a package with the same name is installed from different origins. For example:
yonaskolb/xcodegen
andacecilia/xcodegen
.2- When a package produces multiple executables.
The main additions of this PR are:
list
option.run
option, so it asks for which package to run when multiple origins are detected, instead of just running the first match.uninstall
option, which includes the following fix: previously, the name for the symlink to remove was calculated using the passed package name, which could be partial (for examplesample
instead ofsamplepackage
), resulting on the symlink not being removed. Also added tests