Example #1
0
 protected override void ProcessRecord()
 {
     try
     {
         var logger = new PsCmdletLogger(this);
         s3FileSystem = new S3FileSystem(logger, AccessKey, Secret, new AmazonS3Config());
         s3FileSystem.UploadFiles(new DirectoryInfoWrap(Folder), Recurse, Bucket, SetPublicRead);
     }
     catch (Exception e)
     {
         ThrowTerminatingError(
             new ErrorRecord(
                 e,
                 "Copy-FilesToS3",
                 ErrorCategory.NotSpecified,
                 this
                 )
             );
     }
 }