s3edit allows you to edit files from AWS S3 directly from your terminal.
pip install s3edit
Assuming your file is at
s3edit uses your
EDITOR environmental variable to choose an editor. If not
vi is used by default.
Your AWS profile, credentials, and region needs to be set up for s3edit to work. This can be done through enviromental variables or configuration files. For more information, see https://docs.aws.amazon.com/cli/latest/userguide/cli-chap-welcome.html.