¡Nunca analice html con expresiones regulares! Ese es el error más común en los sitios de intercambio de pilas.
Es mejor usar un analizador XML/HTML como xmllint , xmlstarlet o saxon -lint mi propio proyecto
Ejemplos:
xmllint --xpath '//Currentnumber/text()' file.html
xmlstarlet sel -t -v '//Currentnumber/text()' file.html
saxon-lint --xpath --html '//Currentnumber/text()' file.html