Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content

fix lineage recognition regex

Alexandre Roux requested to merge 7110-fix-bad-recognition-regex into master

Description

Previous regex was recognizing v1.13-rc-t as an R build

this fixes it

Issue(s)

https://gitlab.e.foundation/e/backlog/-/issues/7110

Test environment

tested using a script reproducing this behavior:

the regex displayed was an error

result:

phiestudio@Glitch:~/tmp$ BRANCH_NAME=v1-t bash fixregex.sh
^v[0-9](\.[0-9]*){0,2}(-(beta|alpha|rc)(\.[0-9]*){0,1}){0,1}-(r)(-[a-zA-Z0-9_]*)*$
lineage-20.0
phiestudio@Glitch:~/tmp$ BRANCH_NAME=v1-r bash fixregex.sh
^v[0-9](\.[0-9]*){0,2}(-(beta|alpha|rc)(\.[0-9]*){0,1}){0,1}-(r)(-[a-zA-Z0-9_]*)*$
lineage-18.1
phiestudio@Glitch:~/tmp$ BRANCH_NAME=v1-q bash fixregex.sh
^v[0-9](\.[0-9]*){0,2}(-(beta|alpha|rc)(\.[0-9]*){0,1}){0,1}-(r)(-[a-zA-Z0-9_]*)*$
lineage-17.1
phiestudio@Glitch:~/tmp$ BRANCH_NAME=v1-nougat bash fixregex.sh
^v[0-9](\.[0-9]*){0,2}(-(beta|alpha|rc)(\.[0-9]*){0,1}){0,1}-(r)(-[a-zA-Z0-9_]*)*$
cm-14.1
phiestudio@Glitch:~/tmp$ BRANCH_NAME=v1-nougat bash fixregex.sh
^v[0-9](\.[0-9]*){0,2}(-(beta|alpha|rc)(\.[0-9]*){0,1}){0,1}-(r)(-[a-zA-Z0-9_]*)*$
cm-14.1
phiestudio@Glitch:~/tmp$ BRANCH_NAME=v1-oreo bash fixregex.sh
^v[0-9](\.[0-9]*){0,2}(-(beta|alpha|rc)(\.[0-9]*){0,1}){0,1}-(r)(-[a-zA-Z0-9_]*)*$
lineage-15.1
phiestudio@Glitch:~/tmp$ BRANCH_NAME=v1-pie bash fixregex.sh
^v[0-9](\.[0-9]*){0,2}(-(beta|alpha|rc)(\.[0-9]*){0,1}){0,1}-(r)(-[a-zA-Z0-9_]*)*$
lineage-16.0
phiestudio@Glitch:~/tmp$ BRANCH_NAME=v1-q bash fixregex.sh
^v[0-9](\.[0-9]*){0,2}(-(beta|alpha|rc)(\.[0-9]*){0,1}){0,1}-(r)(-[a-zA-Z0-9_]*)*$
lineage-17.1
phiestudio@Glitch:~/tmp$ BRANCH_NAME=v1-r bash fixregex.sh
^v[0-9](\.[0-9]*){0,2}(-(beta|alpha|rc)(\.[0-9]*){0,1}){0,1}-(r)(-[a-zA-Z0-9_]*)*$
lineage-18.1
phiestudio@Glitch:~/tmp$ BRANCH_NAME=v1-s bash fixregex.sh
^v[0-9](\.[0-9]*){0,2}(-(beta|alpha|rc)(\.[0-9]*){0,1}){0,1}-(r)(-[a-zA-Z0-9_]*)*$
lineage-19.1
phiestudio@Glitch:~/tmp$ BRANCH_NAME=v1-t bash fixregex.sh
^v[0-9](\.[0-9]*){0,2}(-(beta|alpha|rc)(\.[0-9]*){0,1}){0,1}-(r)(-[a-zA-Z0-9_]*)*$
lineage-20.0
phiestudio@Glitch:~/tmp$ BRANCH_NAME=v1.10-r bash fixregex.sh
^v[0-9](\.[0-9]*){0,2}(-(beta|alpha|rc)(\.[0-9]*){0,1}){0,1}-(r)(-[a-zA-Z0-9_]*)*$
lineage-18.1
phiestudio@Glitch:~/tmp$ BRANCH_NAME=v1.10-t bash fixregex.sh
^v[0-9](\.[0-9]*){0,2}(-(beta|alpha|rc)(\.[0-9]*){0,1}){0,1}-(r)(-[a-zA-Z0-9_]*)*$
lineage-20.0
phiestudio@Glitch:~/tmp$ BRANCH_NAME=v1.10.2-t bash fixregex.sh
^v[0-9](\.[0-9]*){0,2}(-(beta|alpha|rc)(\.[0-9]*){0,1}){0,1}-(r)(-[a-zA-Z0-9_]*)*$
lineage-20.0
phiestudio@Glitch:~/tmp$ BRANCH_NAME=v1.10.2-r bash fixregex.sh
^v[0-9](\.[0-9]*){0,2}(-(beta|alpha|rc)(\.[0-9]*){0,1}){0,1}-(r)(-[a-zA-Z0-9_]*)*$
lineage-18.1
phiestudio@Glitch:~/tmp$ BRANCH_NAME=v1.10.2-rc-r bash fixregex.sh
^v[0-9](\.[0-9]*){0,2}(-(beta|alpha|rc)(\.[0-9]*){0,1}){0,1}-(r)(-[a-zA-Z0-9_]*)*$
lineage-18.1
phiestudio@Glitch:~/tmp$ BRANCH_NAME=v1.10.2-rc-t bash fixregex.sh
^v[0-9](\.[0-9]*){0,2}(-(beta|alpha|rc)(\.[0-9]*){0,1}){0,1}-(r)(-[a-zA-Z0-9_]*)*$

Technical details

Screenshots

Check list

  • Self review
  • Test procedure explained
  • Tested on fresh install
  • Tested applied as an update
  • License
  • Internal documentation
  • User documentation
Edited by Alexandre Roux

Merge request reports

Loading