How do I save the GPIO setup?

OK, I just found out through the video below, that it is easy to change the input/output mode:

I still haven’t found a way to save the mode so that the mode is remembered on reboot.