Skip to content

Instantly share code, notes, and snippets.

View edwingsm's full-sized avatar

Edwin George Saju edwingsm

View GitHub Profile
@snarkbait
snarkbait / Direction.java
Created November 29, 2017 08:07
Direction enum class - Advent of Code helper
package util;
/**
* @author /u/Philboyd_Studge on 12/26/2016.
*
* This enum set is for simplifying movement on a 2d integer grid
* Assuming the Y axis is -up(north) and +down(south),
* and X axis is -right(west) and +left(east)
*/
public enum Direction {
@justinpawela
justinpawela / config
Created August 3, 2016 01:39
AWS CodeCommit Multiple Account Config
# This file is: ~/.ssh/config
# You may have other (non-CodeCommit) SSH credentials stored in this
# config file – in addition to the CodeCommit settings shown below.
# NOTE: Make sure to run [ chmod 600 ~/.ssh/config ] after creating this file!
# Credentials for Account1
Host awscc-account1 # 'awscc-account1' is a name you pick
Hostname git-codecommit.us-east-1.amazonaws.com # This points to CodeCommit in the 'US East' region
@weavenet
weavenet / delete_all_object_versions.sh
Created May 4, 2015 05:21
Delete all versions of all files in s3 versioned bucket using AWS CLI and jq.
#!/bin/bash
bucket=$1
set -e
echo "Removing all versions from $bucket"
versions=`aws s3api list-object-versions --bucket $bucket |jq '.Versions'`
markers=`aws s3api list-object-versions --bucket $bucket |jq '.DeleteMarkers'`