How to removing leading section in bash
bash, string
Solution
using just bash facilities
$ s=testFile.txt.1
$ echo ${s%.*}
testFile.txt
$ s=testFile.txt.12345
$ echo ${s%.*}
testFile.txt
to remove before leading zero
$ echo ${s#*.}
txt.12345
Other method, you can split your string up using IFS
$ s=testFile.txt.12345
$ IFS="."
$ set -- $s
$ echo $1
testFile
$ echo $2
txt
$ echo $3
12345
Problem
How can I remove parts of a string up to a certain character? Ex.) If I have the string `testFile.txt.1` and `testFile.txt.12345` how can I remove the `1` and `12345`? EDIT: I meant to remove and throw away the first part of a string up to a certain character and keep the end of it.