Skip to content

Instantly share code, notes, and snippets.

@brandonjp
brandonjp / ScreenshotTimer.scpt
Last active December 26, 2023 22:50 — forked from jonobr1/auto-capture.scpt
A small AppleScript to take a screenshot every X minutes and run for Y hours. Saves to an Image with datetime to your specified folder. Great for recording your workday.
set dir to "~/Dropbox/Dropbox2/ScreenshotTimer/"
do shell script ("mkdir -p " & dir)
set intervalMins to 15 -- Change as per your desired frequency (in minutes)
set durationHours to 8 -- Change as per your desired duration (in hours)
-- Convert minutes to seconds for screenshot interval
set intervalSecs to intervalMins * 60
-- Calculate total repetitions within duration
set totalReps to durationHours * 60 / intervalMins
@brandonjp
brandonjp / insert_snippet.sh
Last active March 10, 2021 19:00
bash script for Alfred workflow to create a new snippet
#!/bin/bash
# set qry to the query (argument one)
qry="$1"
# fix SNIP_DB location in case it contains tilde (won't expand in quotes)
SNIP_DB=$( echo $SNIP_DB | sed "s:^~:$HOME:" )
# set the internal delimeter (idlm) to some char(s) that will never be used
idlm=''
@brandonjp
brandonjp / dabblet.css
Created December 16, 2011 16:09 — forked from LeaVerou/dabblet.css
Previewer test
/**
* Previewer test
*/
background: #f06;
background: linear-gradient(left bottom,
hsla(340, 100%, 50%,.7), yellow);
min-width: 100px;
width: 2in;
transition-duration: 6s;
# rails application template for generating customized rails apps
#
# == requires ==
#
# * rails 2.3+, rspec, cucumber, culerity (langalex-culerity gem), machinist
#
# == a newly generated app using this template comes with ==
#
# * working user registration/login via authlogic, cucumber features to verify that it works
# * rspec/cucumber/culerity for testing