GitHub-Crud
view release on metacpan or search on metacpan
lib/GitHub/Crud.pm view on Meta::CPAN
my $r = $gitHub->exists; # Get the L<sha> of the file via exists if the file exists
return $r->sha if $r; # L<sha> of existing file
undef # Undef if no such file
}
sub deleteSha($) #P Delete a L<sha> that is no longer valid
{my ($gitHub) = @_; # Github
$shas{$gitHub->shaKey} = undef # Mark the L<sha> as deleted
}
sub qm($) #P Quotemeta extended to include undef
{my ($s) = @_; # String to quote
return '' unless $s;
$s =~ s((\'|\"|\\)) (\\$1)gs;
$s =~ s(\s) (%20)gsr; # Url encode blanks
}
sub patKey($) #P Create an authorization header by locating an appropriate personal access token
{my ($gitHub) = @_; # GitHub
$gitHub->loadPersonalAccessToken unless $gitHub->personalAccessToken; # Load a personal access token if none has been supplied
( run in 1.922 second using v1.01-cache-2.11-cpan-b16cb0d3907 )