Powershell Script

Powershell Upload Files to AWS S3

s3

Link to github for a better code reading experience GITHUB

This one writes files to AWS S3. Takes some input parameters. The variable $bucketName, can also be configured as an external parameter, our S3, only has a single bucket for these files, and they get stored under different keys, so this hard coded solution works better for us. The time parameters are only so files, that get corrected the next day get uploaded as yesterdays files to improve idempotency in our use case.

Powershell Write File To UTF-8

powershell

Just a simple program that re-writes files in a folder to UTF-8. A production server I work on had an old version of Powershell running on it and a file needed to be in UTF-8 for it to be read by a Golang-script, so this was created.

This can be run from the terminal by calling the script and passing the logPath and pathToFiles parameters to the Script.

Doesn't write a BOM (Byte Order Mark) on the file, due to the Golang Script reading the file.