Hi all,
I'm looking for a way to pass sed a variable to change an IP address after a user has been asked for information on what IP address they'd like as part of a machine setup script.
I've already saved the relevant ip, subnet, route and gw information into seperate files which I'd like to pass back to sed to insert into the bsd rc.conf file to replace whats there already. The IP information was input using dialog. For example
dialog --backtitle "Network Information" --inputbox "Enter the units IP Address" 10 27 2>/tmp/config1
What I'd like to do is take the contents of config1 and pass it to sed for insertion into rc.conf. Is this possible?
Cheers
millap
I'm looking for a way to pass sed a variable to change an IP address after a user has been asked for information on what IP address they'd like as part of a machine setup script.
I've already saved the relevant ip, subnet, route and gw information into seperate files which I'd like to pass back to sed to insert into the bsd rc.conf file to replace whats there already. The IP information was input using dialog. For example
dialog --backtitle "Network Information" --inputbox "Enter the units IP Address" 10 27 2>/tmp/config1
What I'd like to do is take the contents of config1 and pass it to sed for insertion into rc.conf. Is this possible?
Cheers
millap