~sircmpwn/hare-dev

hare: scripts: add test-genoiddb v1 NEEDS REVISION

Armin Preiml: 1
 scripts: add test-genoiddb

 2 files changed, 9 insertions(+), 0 deletions(-)
#1287728 alpine.yml success
#1287729 freebsd.yml success
#1287730 netbsd.yml success
#1287731 openbsd.yml success
Export patchset (mbox)
How do I use this?

Copy & paste the following snippet into your terminal to import this patchset into git:

curl -s https://lists.sr.ht/~sircmpwn/hare-dev/patches/54136/mbox | git am -3
Learn more about email & git

[PATCH hare] scripts: add test-genoiddb Export this patch

to catch accidental breakages or format changes during build.

Signed-off-by: Armin Preiml <apreiml@strohwolke.at>
---
 .builds/alpine.yml    | 3 +++
 scripts/test-genoiddb | 6 ++++++
 2 files changed, 9 insertions(+)
 create mode 100755 scripts/test-genoiddb

diff --git a/.builds/alpine.yml b/.builds/alpine.yml
index b9c95cce..1c484fde 100644
--- a/.builds/alpine.yml
+++ b/.builds/alpine.yml
@@ -60,6 +60,9 @@ tasks:
- lint: |
    cd hare
    ./scripts/lint.sh
- test-genoiddb: |
    cd hare
    ./scripts/test-genoiddb
- bootstrap: |
    cd hare
    make -j2 bootstrap
diff --git a/scripts/test-genoiddb b/scripts/test-genoiddb
new file mode 100755
index 00000000..d3b8c1cd
--- /dev/null
+++ b/scripts/test-genoiddb
@@ -0,0 +1,6 @@
#!/bin/sh

hare run cmd/genoiddb < encoding/asn1/stdoid/db.txt \
	| diff encoding/asn1/stdoid/db.ha - > /dev/null \
	|| (echo "Either something broke cmd/genoiddb or the database has to" \
		"be generated again." ; exit 1)
-- 
2.45.2
hare/patches: SUCCESS in 1m11s

[scripts: add test-genoiddb][0] from [Armin Preiml][1]

[0]: https://lists.sr.ht/~sircmpwn/hare-dev/patches/54136
[1]: mailto:apreiml@strohwolke.at

✓ #1287731 SUCCESS hare/patches/openbsd.yml https://builds.sr.ht/~sircmpwn/job/1287731
✓ #1287729 SUCCESS hare/patches/freebsd.yml https://builds.sr.ht/~sircmpwn/job/1287729
✓ #1287730 SUCCESS hare/patches/netbsd.yml  https://builds.sr.ht/~sircmpwn/job/1287730
✓ #1287728 SUCCESS hare/patches/alpine.yml  https://builds.sr.ht/~sircmpwn/job/1287728
i'd recommend hooking this into the same infrastructure we use for make 
bootstrap: regenerate the ioddb in the ci build, then let it error out 
when the git status turns out dirty