matrix: Speed up buddy search

hash the matrix id and compare the number instead of comparing
the matrix id string everytime
7 jobs for master in 8 minutes and 25 seconds
Status Job ID Name Coverage
  Build
passed #342287
librem5
build-pureos-gcc-byzantium

00:01:37

 
  Test
passed #342289
librem5
check-po

00:00:18

passed #342288
librem5
test:debian-gcc

00:01:28

23.2%
 
  Package
passed #342290
librem5
package-pureos-byzantium

00:01:43

passed #342291
librem5:arm64
package-pureos-byzantium:arm64

00:05:19

 
  Test Package
passed #342292
librem5
autopkgtest-pureos-byzantium-package

00:01:05

passed #342293
librem5
lintian-pureos-byzantium-package

00:00:39