diff options
author | Florian Pritz <bluewind@xinu.at> | 2019-01-04 13:54:00 +0100 |
---|---|---|
committer | Florian Pritz <bluewind@xinu.at> | 2019-01-04 13:54:00 +0100 |
commit | d4b107f5035413bcf93f24a523a6f8b695ba6b92 (patch) | |
tree | 74f53d2c3cbf7d71264d1c9239d6af21f3038724 /get-arch-keys.pl | |
parent | f2c64faeecf602c024b81fcc3760981e36de45f4 (diff) | |
download | bin-d4b107f5035413bcf93f24a523a6f8b695ba6b92.tar.gz bin-d4b107f5035413bcf93f24a523a6f8b695ba6b92.tar.xz |
Add new scripts
Signed-off-by: Florian Pritz <bluewind@xinu.at>
Diffstat (limited to 'get-arch-keys.pl')
-rw-r--r-- | get-arch-keys.pl | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/get-arch-keys.pl b/get-arch-keys.pl new file mode 100644 index 0000000..b7ee42d --- /dev/null +++ b/get-arch-keys.pl @@ -0,0 +1,16 @@ +#!/usr/bin/perl +use warnings; +use strict; +use JSON; +use WWW::Mechanize; +use v5.10; + +my $url = 'https://www.archlinux.org/master-keys/json/'; + +my $mech = WWW::Mechanize->new(cookie_jar => {}); + +$mech->get($url); +my $json = JSON::decode_json($mech->content()); +for my $node (@{$json->{nodes}}) { + say $node->{key} if $node->{group} eq "packager" and $node->{key}; +} |