@Ryan,
I simplified the code a bit.
I was over-engineering the shell_config_update. I was trying to account for the case where the /etc/default/grub file did not exist and to let the caller handle the behavior of what to do if it did not.
We can add that function later if we want.
For now, the behavior is
- if /etc/default/grub exists and has GRUB_CMDLINE_LINUX_DEFAULT= in it, then edit in place.
- otherwise append to it
@Ryan, update. I was trying to account for the case where the /etc/default/grub file did not exist and to let the caller handle the behavior of what to do if it did not.
I simplified the code a bit.
I was over-engineering the shell_config_
We can add that function later if we want. LINUX_DEFAULT= in it, then edit in place.
For now, the behavior is
- if /etc/default/grub exists and has GRUB_CMDLINE_
- otherwise append to it