Skip to content

Instantly share code, notes, and snippets.

View bnjmn's full-sized avatar

Benjamin Petersen bnjmn

  • Arizona
  • 15:05 (UTC -07:00)
View GitHub Profile
@bnjmn
bnjmn / README.md
Last active December 27, 2018 07:13

examples

I guess you can't make a subdirectory in a gist repo

Last updated: 2015-08-11

Searching for Files

Find mp3 in a directory that are multipart album but not in CD[0-9] folder

exiftool -partofset -directory -filename -r -if '$partofset =~ /^\d\/\d$$/ and $directory =~ /(?<!\d)$$/i and $filetype eq "MP3"' .

Find images in a directory that don't have a DateTimeOriginal

@bnjmn
bnjmn / fabfile.py
Created February 22, 2013 17:04
Fab file from mezzanine. Pretty solid. Storing for reference https://github.com/stephenmcd/mezzanine/blob/master/mezzanine/project_template/fabfile.py
import os
import re
import sys
from functools import wraps
from getpass import getpass, getuser
from glob import glob
from contextlib import contextmanager
from fabric.api import env, cd, prefix, sudo as _sudo, run as _run, hide, task
from fabric.contrib.files import exists, upload_template
@bnjmn
bnjmn / index.html
Created November 17, 2012 18:12
Fingerprint (Demo)
<!DOCTYPE html>
<meta charset="utf-8">
<style>
body {
font: 10px sans-serif;
}
.chord path {
fill-opacity: .67;