Net::G...:Search(3pm)

πŸ“¦
version 1.05 Β· 3 versions
, in ubuntu noble, ubuntu resolute, ubuntu stonking

πŸŽ€ Net::GitHub::V3::Search β€” GitHub Search API πŸ’…

okay bestie, so this is a User Contributed Perl Documentation page for Net::GitHub::V3::Search(3pm), and it's literally the GitHub Search API wrapped up all cute for you. sit down, hydrate, let's go 🌸


✨ NAME ✨

Net::GitHub::V3::Search β€” it's giving GitHub Search API, periodt. πŸ”₯


🌈 SYNOPSIS 🌈

first things first, you load the big one and grab your search object:

use Net::GitHub::V3;

my $gh = Net::GitHub::V3->new; # read L<Net::GitHub::V3> to set right authentication info
my $search = $gh->search;
ngl the comment is important β€” go read Net::GitHub::V3 so your authentication info is actually set right, otherwise you're just a girl standing in front of an API with no credentials 😭

πŸ’œ DESCRIPTION πŸ’œ

πŸ¦‹ METHODS πŸ¦‹

the vibe check link is right here: <http://developer.github.com/v3/search/> β€” that's the whole API she's built on, iykyk.


πŸ“ issues

search the issues, bestie:

my %data = $search->issues({
    q => 'state:open repo:fayland/perl-net-github',
    sort  => 'created',
    order => 'asc',
});
print Dumper(\$data{items});

look at her go β€” querying by state:open and repo:fayland/perl-net-github, sorting by created, ordering asc. iconic. ✨


🧚 repositories

repo search, my beloved:

my %data = $search->repositories({
    q => 'perl',
    sort  => 'stars',
    order => 'desc',
});
print Dumper(\$data{items});

q => 'perl', sort => 'stars', order => 'desc' β€” we're hunting for the most starred perl repos, as we should πŸ’–


πŸ‘‘ code

code search!! main character energy:

my %data = $search->code({
    q => 'addClass in:file language:js repo:jquery/jquery'
});
print Dumper(\$data{items});

one query, all the qualifiers β€” addClass in:file language:js repo:jquery/jquery β€” she's specific and she's right 🫢


πŸ’€ users

and finally, the people:

my %data = $search->users({
    q => 'perl',
    sort  => 'followers',
    order => 'desc',
});
print Dumper(\$data{users});

q => 'perl', sort => 'followers', order => 'desc' β€” finding the perl people with the most followers fr fr. also notice this one dumps $data{users} not $data{items}, so don't get it twisted πŸ™ˆ


Refer Net::GitHub β€” that's the whole thing, bestie, all the author/copyright/license tea lives over in Net::GitHub 🌈


k bye, love u, go search something iconic ✨

this page was served up by perl v5.36.0 on 2022-10-08 β€” she's a lil vintage but she ate πŸ’…

πŸ“¦ where this page comes from