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

Change name of plugin target to readable form #505

Merged
merged 3 commits into from Oct 18, 2022

Conversation

clayellis
Copy link
Contributor

This PR updates the name of the "Generate Manual" plugin so that it appears in a more readable "command" form in the context menu in Xcode.

Before:
image

After:
image

Checklist

  • I've added at least one test that validates that my change is working, if appropriate
  • I've followed the code style of the rest of the project
  • I've read the Contribution Guidelines
  • I've updated the documentation if necessary

@clayellis
Copy link
Contributor Author

Arguably, there should be an additional parameter on the Plugin target type that allows for an easier "external" name configuration without having to rename actual targets. Maybe it's worth a pitch? Someone else may have to take it up, though.

@rauhul
Copy link
Contributor

rauhul commented Oct 14, 2022

I'm on board with making the name look better in Xcode, though I'm not a huge fan of having a space in the file path.

@neonichu do you have any thoughts, is this the best solution for improving the display name in Xcode?

@neonichu
Copy link
Member

Yep, right now this is the only way. I do think it might be worthwhile to separately look into extending the PluginCommandIntent to offer a display name to separate this from the target name.

@clayellis
Copy link
Contributor Author

clayellis commented Oct 15, 2022

I'm on board with making the name look better in Xcode, though I'm not a huge fan of having a space in the file path.

This avoids having a space in the file path (by explicitly declaring a path) and moves the space into the target name.

Copy link
Member

@natecook1000 natecook1000 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since this keeps the command-line verb the same, it looks like the change is really kept local to the package manifest, which then gets picked up by Xcode for the action name. Given that, I think this is fine to merge, especially since it doesn't bind us with source compatibility or anything else if we do discover problems down the road.

@natecook1000
Copy link
Member

@swift-ci Please test

@natecook1000 natecook1000 merged commit 76259eb into apple:main Oct 18, 2022
@clayellis clayellis deleted the generate-manual-plugin-name branch October 19, 2022 18:10
@clayellis
Copy link
Contributor Author

Thanks for merging this! I hope to contribute in larger ways in the future!

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

4 participants