Ariadne OpenGPG Claim: openpgp4fpr:50fec3a364b59bee734d0e9b56a3789ced4d2dd7
#!/bin/sh | |
# Loads and unloads secrets from pass into shell environment variables. | |
# Usage: | |
# # Load secrets: | |
# $ source secrets.sh | |
# | |
# # Unload secrets | |
# $ source secrets.sh unload | |
# |
This script converts JSON file from Simplenote Export web service into individual Markdown files.
It's nothing fancy, first argument is the JSON file, second argument is directory to write the notes to. The note files are named by using the first 60 characters (or a little more, up to a full word) of the first line of the note, stripped of any characters outside of letters, simple dash, underscore, brackets, space, single quote, and plug and equal signs.
Tags are stored on the bottom of the note on a line starting with "TAGS:", and the SimpleNote note ID/key as a "KEY:" line.
import codecs | |
from datetime import datetime | |
import json | |
import os | |
import posixpath | |
import re | |
import shutil | |
import sys | |
# This script will import your instagram photos to your static site. It should work for most, assuming you customize the POST_TEMPLATE to match what your site uses. |
on run | |
set vol_level to (input volume of (get volume settings)) | |
if (vol_level < 1) then | |
set volume input volume ReadVolumeLevel() | |
else | |
set volume input volume 0 | |
WriteVolumeLevel(vol_level) | |
return vol_level | |
end if |
from datetime import date | |
import sqlite3 | |
EPOCH_OFFSET = 978278400 | |
conn = sqlite3.connect('banktivity.sql') | |
conn.row_factory = sqlite3.Row | |
first_date = None | |
accounts = set([]) |
# This is particularly useful when your doc strings are written in rST as part of | |
# a bigger project, but are also needed to be displayed elsewhere, for when when | |
# generating code. | |
""" | |
This is intended to have similar interface to doctools.core (specifically | |
publish_string level of methods), but still could use more cleanup. Plaintext | |
output is assumed. Changing this would require tinkering with the Sphinx writers. | |
""" | |
import docutils.io |
Playground gist for bl.ocks.org
A basic example of using mbostock's weekday.js gist to to plot only weekdays using a linear scale. The resulting charts will not show gaps where weekends would be.
{ | |
"cells": [ | |
{ | |
"cell_type": "code", | |
"execution_count": 3, | |
"metadata": { | |
"collapsed": false | |
}, | |
"outputs": [ | |
{ |