In a previous article, I introduced a way to install multiple versions at the same time Xcode Tool ofUse xcode-install to manage Xcode versionsBut when there are multiple Xcodes in your system at the same time,Will cause system confusion,Make Xcode plugins unrecognizable,The main manifestation is that it is not visible at all in the system preferences Xcode pluginOptions-as if you haven't installed them at all。
Anyway,I'm hereHereFound the answer
First execute the command:
1 |
PATH=/System/Library/Frameworks/CoreServices.framework/Frameworks/LaunchServices.framework/Support:"$PATH" |
This command will temporarily add the path of a tool to our environment,Convenient to execute the next command:
1 |
lsregister -f /Applications/Xcode.app |
This command triggers the system to re-register Xcode to the system,note,Here Xcode's path must be your real path,For example, I currently have Xcode-12.2.app in my system,And Xcode-12.1.app,Then I will execute the command like this: lsregister -f /Applications/Xcode-12.2.app
After the command is executed, go to the system preferences to view,You can see the familiar Xcode extension enable interface。
Original article written by LogStudio:R0uter's Blog » Xcode plugin is missing and does not display the solution
Reproduced Please keep the source and description link:https://www.logcg.com/archives/3437.html
Thanks big guy,Amazing,Solve the problem successfully
Be aware that sometimes it will be lost,Just re-execute this command 🥲