classes/sanity: De-golf regex
PATCH 1/1 classes/sanity: De-golf regex
The regex to match github or gitlab was unnecessarily shortened, which prevented them from showing up when grepping.
--- meta/classes/insane.bbclass | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
meta/classes/insane.bbclass +1 -1
@@ -1335,7 +1335,7 @@ def unpack_check_src_uri(pn, d): oe.qa.handle_error("src-uri-bad", "%s: SRC_URI uses PN not BPN" % pn, d) for url in d.getVar("SRC_URI").split(): - if re.search(r"git(hu|la)b\.com/.+/.+/archive/.+", url): + if re.search(r"(github|gitlab)\.com/.+/.+/archive/.+", url): oe.qa.handle_error("src-uri-bad", "%s: SRC_URI uses unstable GitHub/GitLab archives, convert recipe to use git protocol" % pn, d) python do_qa_unpack() {
Signature · 1 line
2.33.0
Hi Joshua,
Quoted 4 lines · On Mon, 8 Aug 2022 08:19:51 -0500 Joshua Watt <[email protected]> wrote:
The regex to match github or gitlab was unnecessarily shortened, which prevented them from showing up when grepping.
Signed-off-by Joshua Watt <[email protected]>
Thank you!
Signature · 3 lines
Luca Ceresoli, Bootlin Embedded Linux and Kernel engineering https://bootlin.com
Hi,
Quoted 3 lines · Joshua Watt
The regex to match github or gitlab was unnecessarily shortened, which prevented them from showing up when grepping.
This doesn't apply since we have "classes/sanity: Add comment about github & gitlab archives" in master. I guess this was one or the other.
Quoted 31 lines
Signed-off-by Joshua Watt <[email protected]>--- meta/classes/insane.bbclass | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)meta/classes/insane.bbclass +1
-1@@ -1335,7 +1335,7 @@ def unpack_check_src_uri(pn, d): oe.qa.handle_error("src-uri-bad", "%s: SRC_URI uses PN not BPN" % pn, d) for url in d.getVar("SRC_URI").split(): - if re.search(r"git(hu|la)b\.com/.+/.+/archive/.+", url): + if re.search(r"(github|gitlab)\.com/.+/.+/archive/.+", url): oe.qa.handle_error("src-uri-bad", "%s: SRC_URI uses unstable GitHub/GitLab archives, convert recipe to use git protocol" % pn, d) python do_qa_unpack() {Signature · 11 lines
2.33.0 -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#169085): https://lists.openembedded.org/g/openembedded-core/message/169085 Mute This Topic: https://lists.openembedded.org/mt/92891575/3617179 Group Owner: [email protected] Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [[email protected]] -=-=-=-=-=-=-=-=-=-=-=-
Signature · 3 lines
Alexandre Belloni, co-owner and COO, Bootlin Embedded Linux and Kernel engineering https://bootlin.com
Quoted 10 lines · Alexandre Belloni
Hi,
Quoted 3 lines · Joshua Watt
The regex to match github or gitlab was unnecessarily shortened, which prevented them from showing up when grepping.
This doesn't apply since we have "classes/sanity: Add comment about github & gitlab archives" in master. I guess this was one or the other.
Ack, sorry. This was due to feedback on that patch, and I didn't realize it had merged already. Sorry about that. It doesn't really matter to me which one was merged, so dropping this is fine
I think I should have done this one as a V2, or at least in-reply-to that one?
Quoted 38 lines
Quoted 24 lines
Signed-off-by Joshua Watt <[email protected]>--- meta/classes/insane.bbclass | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)meta/classes/insane.bbclass +1
-2@@ -1335,7 +1335,7 @@ def unpack_check_src_uri(pn, d): oe.qa.handle_error("src-uri-bad", "%s: SRC_URI uses PN not BPN" % pn, d) for url in d.getVar("SRC_URI").split(): - if re.search(r"git(hu|la)b\.com/.+/.+/archive/.+", url): + if re.search(r"(github|gitlab)\.com/.+/.+/archive/.+", url): oe.qa.handle_error("src-uri-bad", "%s: SRC_URI uses unstable GitHub/GitLab archives, convert recipe to use git protocol" % pn, d) python do_qa_unpack() { --2.33.0
Quoted 8 lines
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#169085): https://lists.openembedded.org/g/openembedded-core/message/169085
Mute This Topic: https://lists.openembedded.org/mt/92891575/3617179
Group Owner: [email protected]
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [[email protected]]
-=-=-=-=-=-=-=-=-=-=-=---
Alexandre Belloni, co-owner and COO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
De-golf?
LoL: https://www.explainxkcd.com/wiki/index.php/1313:_Regex_Golf
on "regex golf <http://regex.alf.nu/>", which is a discipline of "code golf <https://en.wikipedia.org/wiki/Code_golf>", a game in which programmers attempt to solve a given programming problem using as few characters as possible,
I need to get out more!
../Randy
Quoted 30 lines · Joshua Watt
The regex to match github or gitlab was unnecessarily shortened, which prevented them from showing up when grepping.
Signed-off-by Joshua Watt<[email protected]>--- meta/classes/insane.bbclass | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)meta/classes/insane.bbclass +1
-2@@ -1335,7 +1335,7 @@ def unpack_check_src_uri(pn, d): oe.qa.handle_error("src-uri-bad", "%s: SRC_URI uses PN not BPN" % pn, d) for url in d.getVar("SRC_URI").split(): - if re.search(r"git(hu|la)b\.com/.+/.+/archive/.+", url): + if re.search(r"(github|gitlab)\.com/.+/.+/archive/.+", url): oe.qa.handle_error("src-uri-bad", "%s: SRC_URI uses unstable GitHub/GitLab archives, convert recipe to use git protocol" % pn, d) python do_qa_unpack() { -=-=-=-=-=-=-=-=-=-=-=-Links: You receive all messages sent to this group.
View/Reply Online (#169085):https://lists.openembedded.org/g/openembedded-core/message/169085 Mute This Topic:https://lists.openembedded.org/mt/92891575/3616765
Group Owner:[email protected] Unsubscribe:https://lists.openembedded.org/g/openembedded-core/unsub [[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-
Signature · 2 lines
# Randy MacLeod # Wind River Linux