PhpStorm Settings Repository Commit on repo without HEAD not supported

This seems to be a bug in the Settings repository plugin of different JetBrains IDEs. A functioning workaround is to delete the local Git repository in the IDE's config directory:

${HOME}/.<IDE>/config/settingsRepository/repository

Please refer to this site for the exact directory name of your IDE on your operating system:

https://intellij-support.jetbrains.com/hc/en-us/articles/206544519-Directories-used-by-the-IDE-to-store-settings-caches-plugins-and-logs

The workaround was posted in the JetBrains bug report (for IntelliJ IDEA):

https://youtrack.jetbrains.com/issue/IDEA-152002#comment=27-2918113