Skip to content

Instantly share code, notes, and snippets.

View cazzerson's full-sized avatar

Jason Casden cazzerson

View GitHub Profile
@cazzerson
cazzerson / NC-HB2-ids.sh
Created January 12, 2017 15:56
Extracting HB2 Tweet IDs from multiple twarc datasets
# This script requires the jq utility
# https://stedolan.github.io/jq/
# Datasets created with twarc
# https://github.com/DocNow/twarc
mkdir -p NCHB2-ids
rm NCHB2-ids/NCHB2*
touch NCHB2-ids/NCHB2-ids-with-dupes.txt
# Create more relevant subset of "North Carlina" search
@cazzerson
cazzerson / export-all-users.py
Last active February 21, 2017 16:05
A quick management command to export all user tweets from the old Social Feed Manager. This may require an older version of openpyxl if you've updated the packages recently. Place this file in `sfm/ui/management/commands/`, create an `sfm/exports` directory, then: `cd sfm` and `./manage.py export-all-users`. Then look in the `exports` directory.
import codecs
from optparse import make_option
import sys
from django.core.management.base import BaseCommand, CommandError
from ui.models import TwitterUser, TwitterUserSet, TwitterUserItem
from ui.utils import make_date_aware, xls_tweets_workbook
import os
@cazzerson
cazzerson / vuetify.js
Created August 15, 2017 17:20
Vuetify with detachable-root mods from vanhoavn
(function webpackUniversalModuleDefinition(root, factory) {
if(typeof exports === 'object' && typeof module === 'object')
module.exports = factory();
else if(typeof define === 'function' && define.amd)
define([], factory);
else if(typeof exports === 'object')
exports["Vuetify"] = factory();
else
root["Vuetify"] = factory();
})(this, function() {
@cazzerson
cazzerson / vuetify.js
Created August 15, 2017 17:20
Vuetify with detachable-root mods from vanhoavn
(function webpackUniversalModuleDefinition(root, factory) {
if(typeof exports === 'object' && typeof module === 'object')
module.exports = factory();
else if(typeof define === 'function' && define.amd)
define([], factory);
else if(typeof exports === 'object')
exports["Vuetify"] = factory();
else
root["Vuetify"] = factory();
})(this, function() {