You can’t save them on the device, you will just have to paste them in after doing the upgrade
I have a large script i run after upgrade that sets all my settings for me and reboots.