Skip to content

Instantly share code, notes, and snippets.

@metaist
metaist / HebCal.bas
Created December 7, 2012 02:06
Convert dates using HebCal's web service.
'Version 0.1.2 // 2012-12-07
'Required References:
' Microsoft Scripting Library
' Microsoft XML
Dim cache As New Dictionary
Dim fso As New FileSystemObject
Public Const LIMIT_CACHE = False 'keep cache small
Public Const REFRESH_CACHE = True 'delete old cache
@metaist
metaist / google-docs.ahk
Created March 12, 2013 00:13
Control Google Docs using AutoHotKey.
; Google Docs Utility Functions
SavePDF(filename) {
SendInput,!f
Sleep,200
SendInput,d
Sleep,200
SendInput,{Down}
Sleep,200
SendInput,{Down}
@metaist
metaist / jsonwiki.py
Created June 7, 2013 14:32
Convert tables from Wikipedia into JSON.
#!/usr/bin/env python
"""Convert tables from Wikipedia into JSON."""
import argparse
import json
import sys
from bs4 import BeautifulSoup
import requests
@metaist
metaist / bootstrap-vertical-grid.css
Created November 24, 2013 21:06
Bootstrap vertical grid. For laying out full-screen fixed height webapps.
.container-fixed {
bottom: 0;
position: fixed;
left: 0;
right: 0;
top: 0;
}
.container-fixed .col {
height: 100%;
@metaist
metaist / object-filter.js
Created March 19, 2014 02:32
Add .filter to JavaScript objects.
// Based on: http://stackoverflow.com/a/5072145/12815
Object.filter = function(obj, predicate) {
var result = {}, key;
for(key in obj) {
if (obj.hasOwnProperty(key) && predicate.call(obj, key, obj[key])) {
result[key] = obj[key];
}//end if: key added to result
}//end for: iterated over the object
return result;
@metaist
metaist / index.html
Created April 3, 2014 02:47
wordeck - words in a deck
<!DOCTYPE html>
<html><head>
<title>wordeck - words in a deck</title>
<link rel="stylesheet" href="//netdna.bootstrapcdn.com/bootstrap/3.1.1/css/bootstrap.min.css" />
<link rel="stylesheet/less" href="wordeck.less" />
<script src="//cdnjs.cloudflare.com/ajax/libs/less.js/1.7.0/less.min.js"></script>
</head><body class="mode-edit">
<nav class="navbar navbar-default" role="navigation">
<div class="navbar-header">
<a class="navbar-brand" href="#">wordeck</a>
@metaist
metaist / ytdl.sh
Created July 6, 2014 15:59
YouTube Batch Downloader
#!/bin/bash
youtube-dl --batch-file $1 --extract-audio --output '%(autonumber)s-%(title)s-%(id)s.%(ext)s'
@metaist
metaist / Standalone-Chrome-Apps.markdown
Created September 18, 2014 15:35
Building, installing, and running a Standalone Chrome App

Build, Install, and Run a Chrome App without Chrome

Until [app_shell] is created, here is a workaround for building, installing, and running a standalone [Chrome App] for Windows.

Step 1 - Pack Your Chrome App

  1. Use chrome://extensions to package your app. The approach we're outlining here doesn't work for unpacked apps.
  2. You should have a .crx file that is your packaged app.
@metaist
metaist / README.markdown
Last active August 29, 2015 14:06
Chrome App: Hello World + Canvas
@metaist
metaist / tools.markdown
Last active August 29, 2015 14:07
Useful tools.