Skip to content

Instantly share code, notes, and snippets.

@djkmiles
djkmiles / timetrial.sh
Created May 7, 2015 21:48
An alias/function pair for reliable use in .bash_profile or similar file, execute a script and compute the duration.
function f_timetrial() {
echo "Please wait for $1 computation(s) of $2";
echo "Average:" $(for i in `seq 1 $1`; do time /bin/sh $2; done 2>&1 | grep ^real | sed -e s/.*m// | awk '{sum += $1} END {print sum / NR}';) "Second(s)."
}
alias timetrial=f_timetrial;
@djkmiles
djkmiles / designer.html
Created December 10, 2014 15:34
designer
<link href="../paper-tabs/paper-tabs.html" rel="import">
<link href="../paper-tabs/paper-tab.html" rel="import">
<link href="../core-icons/core-icons.html" rel="import">
<link href="../core-icons/av-icons.html" rel="import">
<link href="../paper-fab/paper-fab.html" rel="import">
<polymer-element name="my-element">
<template>
<style>