Hi, I'm writing a shell script in which I need to solve this situation:
I have a string:
my_string="some_very_long_string" and I need to replace the last character of this string with a '0'. How can I do that?
And when I run this script, i read this string from the command line parameter so the string length is variable.
Also, is there a link that has useful string manipulation routines for shell scripting?
Thanks,
Sashi
I have a string:
my_string="some_very_long_string" and I need to replace the last character of this string with a '0'. How can I do that?
And when I run this script, i read this string from the command line parameter so the string length is variable.
Also, is there a link that has useful string manipulation routines for shell scripting?
Thanks,
Sashi