Amazon-S3Curl-PurePerl
view release on metacpan or search on metacpan
lib/Amazon/S3Curl/PurePerl.pm view on Meta::CPAN
}
sub upload_cmd {
my ($self) = @_;
my $url = $self->url;
#trailing slash for upload means curl will plop on the filename at the end, ruining the hash signature.
if ( $url =~ m|/$| ) {
my $file_name = ( File::Spec->splitpath( $self->local_file ) )[-1];
$url .= $file_name;
}
my $args = $self->_req('PUT',$url);
splice( @$args, $#$args, 0, "-T", $self->local_file );
return $args;
}
sub delete_cmd {
my $args = shift->_req('DELETE');
splice( @$args, $#$args, 0, qw[ -X DELETE ] );
return $args;
}
( run in 0.285 second using v1.01-cache-2.11-cpan-4e96b696675 )