-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Add subcommands to install and uninstall packages #6768
Add subcommands to install and uninstall packages #6768
Conversation
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.
Overall I'm happy to see that the scope of the change is reduced, but this needs path and directory layout handling unified, formatting cleanups, usage of CLI options instead of interactive input, and improved testability through the use of FileSystem
.
Seems like everything here has been addressed, could you take a look now? |
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.
We're getting much closer, but I still have a couple of comments on naming and formatting.
@@ -465,7 +485,7 @@ extension FileSystem { | |||
return try swiftSDKsDirectory | |||
} | |||
} | |||
|
|||
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.
nit: unnecessary trailing newline. To get rid of these altogether you can run ./Utilities/soundness.sh
in this package, assuming you have SwiftFormat installed.
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.
Resolving locally
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.
would you be able to push that formatting fix to this branch as well?
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.
still present in the diff
} | ||
|
||
try tool.fileSystem.removeFileTree(whatWeWantToRemove.url) | ||
print("Removed \(name).") |
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.
Make this more descriptive:
print("Removed \(name).") | |
print("Executable product `\(name)` was successfully uninstalled from \(removedExecutable.path).") |
@MaxDesiatov All addressed. |
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.
Thanks! I've addressed formatting issues in a follow-up commit. For the future when contributing to SwiftPM I highly recommend following CONTRIBUTING.md
, esp. item 6 WRT formatting and use of SwiftFormat.
@swift-ci smoke test |
@swift-ci smoke test |
@swift-ci test windows |
@swift-ci smoke test |
@swift-ci test windows |
@swift-ci smoke test |
@swift-ci test windows |
1 similar comment
@swift-ci test windows |
Rewritten continuation of #5591, however the
update
subcommand has been taken out temporarily as we figure out the remote-scm situation right now.This adds
swift package experimental-install
andswift package experimental-install
. Theexperimental-
prefix is added since this hasn't gone through Swift Evolution yet.