📜  列出s3文件夹中的文件python代码示例

📅  最后修改于: 2022-03-11 14:46:19.133000             🧑  作者: Mango

代码示例1
import boto3

s3 = boto3.resource('s3')
my_bucket = s3.Bucket('my_bucket_name')

for object_summary in my_bucket.objects.filter(Prefix="dir_name/"):
    print(object_summary.key)