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
$dcim_dir = "X:\Pictures\dcim\rt" | |
if ($args[0]) { | |
# Passed paths? Act on those. | |
$files = foreach ($file in $args) { | |
Get-ChildItem -Path $file | |
} | |
} | |
else { |
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/zsh | |
rp=${1:a} | |
wd=${rp:a:h} | |
f=${rp:t} | |
pfx=${f:r} | |
outfile=$pfx.gif | |
#dump out all the frames using libwebp/examples/anim_dump | |
anim_dump -folder $wd -prefix ${pfx}_ $f |
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
{ | |
"consumer_key": "", | |
"consumer_secret": "", | |
"access_token": "", | |
"access_token_secret": "" | |
} |
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 node | |
var fs = require("fs"); | |
var path = require("path"); | |
var Twit = require("twit"); | |
var credentials = readCredentials(); | |
var twitter = new Twit(credentials); | |
var CAVESPATH = process.env["CAVESPATH"]; // e.g. "/home/ian/caves" | |
// UTILITY: Get "random" element from array: |
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 random | |
def char_error(s): | |
t = "" | |
for ch in s: | |
if random.randrange(6) == 0: | |
t += chr(ord(ch)+random.choice([-1,1])) | |
else: | |
t += ch | |
return t |
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
/* Builds on bootstrap */ | |
/* Numbering page listing, since our templating is logicless */ | |
ol.pagination { | |
counter-reset: page-number | |
} | |
ol.pagination > li > a.page-link::before { | |
counter-increment: page-number; | |
content: counter(page-number); | |
} |