s3_list: AWS S3 functions

Description Usage Arguments Value Note

View source: R/aws_s3.R

Description

This function retrieves a list of objects from a bucket of the Amazon S3 service and generate url for each one. The default base url text used to form the final url is given by getOption("s3_base_url", "https://%s.s3.amazonaws.com/%s"), where the two formating text parameters %s correspond to the bucket name and the object key, respectively.

Use regex parameter to filter those objects of your interest.

Usage

1
s3_list(bucket, regex = ".*\\.tif$", ...)

Arguments

bucket

A character text informing an existing bucket.

regex

A character with regular expression indicating which files will be included.

...

Any extra arguments to be passed to aws.s3 package to access the bucket.

Value

A character vector of object's url.

Note

You must set Sys.setenv("AWS_ACCESS_KEY_ID", <your_key>) and Sys.setenv("AWS_SECRET_ACCESS_KEY", <your_access_key>) to have access to an aws.s3 bucket object. If you prefer, you can pass access parameters to ... argument the same used by aws.s3 package. For more details see https://github.com/cloudyr/aws.s3.


rolfsimoes/coverage documentation built on May 24, 2019, 9:48 p.m.