Development on STM32 Nucleo boards: do we necessarily need STM32CubeMX for generating config files?

I am reading a lot about various boards and I watched a nice tutorial on STM32Cube where there is a GUI where the user select the nature of the various pins of the uC, set the timers, etc. and then the tool generate some .h and .c files.

Next, I read that one could copy these files into his platformio project and can continue the development in the IDE he/she wants (vim, VSCode, Notepad, etc.)

I have also seen that to install STM32CubeMX I need to install XCode and Rosetta, which I would avoid to install.

Hence, the question: do we necessarily need STM32CubeMX for generating such configuration files? Does platformio offer any workaround (for example, it can generate the “defaults” for a specific board)?