Skip to content

Instantly share code, notes, and snippets.

@alexdebrie
alexdebrie / README.md
Created February 1, 2019 01:59
Using boto3 generate_presigned_post()

Using an S3 presigned POST url.

  1. Copy the generate.py script to your machine.

  2. Update the BUCKET_NAME and KEY_NAME values in the script as needed.

  3. Run python generate.py. It will spit some output like the following:

$ python3 generate.py

@namongk
namongk / uninstall.sh
Created March 2, 2017 06:16
Uninstall docker toolbox
#!/bin/bash
# Uninstall Script
if [ "${USER}" != "root" ]; then
echo "$0 must be run as root!"
exit 2
fi
while true; do
@acdha
acdha / pre-commit
Last active April 18, 2024 02:22
Git pre-commit hook which runs various code linters. Install this to .git/hooks/pre-commit inside your favorite repos
#!/usr/bin/env PYTHONIOENCODING=utf-8 python
# encoding: utf-8
"""Git pre-commit hook which lints Python, JavaScript, SASS and CSS"""
from __future__ import absolute_import, print_function, unicode_literals
import os
import subprocess
import sys