Thanks for clarification, so next script saved space station with kerbals onboard
#!/bin/bash
# Quite many lines, could be combined into one sed invocation, but self explaining
sed -i 's/ModuleAmpYearPPTRCS/ModulePPTPoweredRCS/' persistent.sfs
sed -i 's/ModuleAmpYearPoweredRCS/ModuleIONPoweredRCS/' persistent.sfs
sed -i 's/AmpYearIONRCSBlock45/IONRCSBlock45/' persistent.sfs
sed -i 's/AmpYearIONRCSBlock/IONRCSBlock/' persistent.sfs
sed -i 's/ampYearLinearIonRCS/LinearIonRCS/' persistent.sfs
sed -i 's/ampYearLinearPPTRCS/LinearPPTRCS/' persistent.sfs
Maybe it would help someone else.