(C-x means ctrl+x, M-x means alt+x)
The default prefix is C-b. If you (or your muscle memory) prefer C-a, you need to add this to ~/.tmux.conf
:
#!/usr/bin/python2.7 | |
# -*- coding: utf-8 -*- | |
# vim:ts=4:sw=4:softtabstop=4:smarttab:expandtab | |
""" | |
Watch for new downloads in ~/Downloads (or another directory) and take actions. | |
The actions are determined by the file extension (determining the mime type). | |
""" | |
from __future__ import absolute_import | |
from __future__ import print_function |
def copy_row(model, row, ignored_columns=[]): | |
copy = model() | |
for col in row.__table__.columns: | |
if col.name not in ignored_columns: | |
try: | |
copy.__setattr__(col.name, getattr(row, col.name)) | |
except Exception as e: | |
print e | |
continue |
<?xml version="1.0" encoding="UTF-8"?> | |
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | |
<plist version="1.0"> | |
<dict> | |
<key>Label</key> | |
<string>local.IDENTIFIER_HERE.SOMETHING</string> | |
<key>KeepAlive</key> | |
<false/> | |
<key>RunAtLoad</key> | |
<false/> |
from sqlalchemy import create_engine, MetaData | |
from sqlalchemy.ext.automap import automap_base | |
from sqlalchemy.orm import sessionmaker | |
def create_sa_connection(connection): | |
engine = create_engine(connection, echo=False) | |
Session = sessionmaker(bind=engine) | |
return engine, session() |
# THIS PROJECT IS AN EXAMPLE APP. SOME CODE MAY NOT BE ACTUALLY USEFUL | |
# FOR DEMONSTRATION PURPOSES ONLY | |
# YOUR MILEAGE MAY VARY | |
import os | |
from flask import (Flask, | |
Blueprint, | |
redirect, |
# THIS PROJECT IS AN EXAMPLE APP. SOME CODE MAY NOT BE ACTUALLY USEFUL | |
# FOR DEMONSTRATION PURPOSES ONLY | |
# YOUR MILEAGE MAY VARY | |
# Requirements are Flask, Flask-WTF, Flask-SQLAlchemy | |
import os | |
from flask import (Flask, | |
Blueprint, | |
redirect, |
# THIS PROJECT IS AN EXAMPLE APP. SOME CODE MAY NOT BE ACTUALLY USEFUL | |
# FOR DEMONSTRATION PURPOSES ONLY | |
# YOUR MILEAGE MAY VARY | |
# Requirements are Flask, Flask-WTF, Flask-SQLAlchemy, bcrypt | |
import os | |
from flask import (Flask, | |
Blueprint, | |
redirect, |
#!/usr/bin/env bash | |
# This is part of a larger script for setting a mac for python development. | |
set -e | |
# Shared functions | |
pretty_print() { | |
printf "\n%b\n" "$1" | |
} |
{ | |
"DLM": 0, | |
"attachments-count": 0, | |
"boardColumn": { | |
"color": "#0AD2F5", | |
"id": 12044, | |
"name": "In Progess" | |
}, | |
"canComplete": true, | |
"canEdit": true, |