The instructions are simple (or they worked too well...)
- uninstall pycharm by removing it from applications
- download the arch m1 chip dmg and download it.
That's all.
Although I did save the setting by going to
File | Manage IDE Settings | Export Settings
I did not need to import them since I opened the new pycharm and it already new everything. Also even though I saved the .idea
folder of my previous project (which was at the root of the folder with the folder name of the github repo that created the project, if you can't find the .idea folder see Show .idea folder in PhpStorm project tool window) I didn't end up needed it. Creepy but I guess thats fine.
If you get the following error
xcrun: error: unable to load libxcrun (dlopen(/Library/Developer/CommandLineTools/usr/lib/libxcrun.dylib, 0x0005): tried: '/Library/Developer/CommandLineTools/usr/lib/libxcrun.dylib' (mach-o file, but is an incompatible architecture (have 'x86_64', need 'arm64e')), '/usr/lib/libxcrun.dylib' (no such file)).
do the following (source):
What I suggest is to uninstall the command line tools (CLT) and re-install them the official way (source).
So do (source):
sudo rm -rf /Library/Developer/CommandLineTools
check it uninstalled, you should get an output as follows:
xcode-select -p
output
xcode-select: error: unable to get active developer directory, use `sudo xcode-select --switch path/to/Xcode.app` to set one (or see `man xcode-select`)
then install the command line tools (CLT) again:
xcode-select --install
then agree to it and it should download after a couple of minutes. The download should take some time. For me ~13mins.
After that your issues with PyCharm, git, brew and likely other tools will be resolved.