This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"Description": "Base Template to create Neptune Stack inside a VPC", | |
"Parameters": { | |
"Env": { | |
"Description": "Environment tag, e.g. prod, nonprod.", | |
"Default": "test", | |
"Type": "String", | |
"AllowedPattern": "[a-z0-9]+", | |
"MaxLength": 15 | |
}, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# EditorConfig helps developers define and maintain consistent coding styles | |
# between different editors and IDEs. See more and available editor plugins at: | |
# https://editorconfig.org/#download | |
# | |
# Below are some defaults for Narrativ developers, with required values are | |
# marked as such. Everything else is may be updated to your personal | |
# preference. | |
# remove // set to false if project-specific | |
root = true |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
import sys | |
def PascalsTriangle(row): | |
max_row = int(row) | |
triangle = [] | |
current_row = 0 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import json | |
from urllib import request | |
from pprint import pprint | |
def main(): | |
weather_req = request.urlopen("http://api.wunderground.com/api/872a930f94a85692/conditions/q/UK/London.json") | |
# read the request and decode the bytes into sensible UTF-8 strings | |
weather_data = weather_req.read().decode("utf-8") | |
# take a peak at the mess of it |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python | |
"""Randomly select your March Madness bracket. | |
""" | |
import random | |
south = ( | |
( |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
APP_PATH=$HOME/app | |
PYTHON_KERNEL=$APP_PATH/venv/bin/python | |
function install_pip { | |
echo -e 'downloading pip...' | |
curl -SLO https://bootstrap.pypa.io/get-pip.py | |
echo -e 'installing pip...' | |
python get-pip.py |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/local/bin/python3 | |
import inspect | |
import random | |
class Foo(object): | |
def a_method(self, x, y, z): | |
print('Your method ran:\n', x, y, z) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
usage () { | |
echo "usage:" $@ | |
exit 127 | |
} | |
die () { | |
echo $@ | |
exit 128 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import collections | |
from pprint import pprint | |
my_dict = { | |
'one': { | |
'one-one': True, | |
'one-two': False, | |
'one-three': { | |
'one-three-one': True, | |
}, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
// Matt's Sublime SFTP settings for developing on a remote server | |
// This setup assumes you are using both an SSH key (as you should) and SFTP | |
// sftp, ftp or ftps | |
"type": "sftp", | |
"sync_skip_deletes": false, | |
"sync_same_age": true, | |
"confirm_downloads": false, |
NewerOlder