Joined January 2014
·

Maikel

Netherlands
·
·
·

Posted to Free MySQL OS X client over 1 year ago

I used it also a lot, but now I'm using mainly Postgresql. Really a bummer Sequel Pro does not support that.

I run Docker on Ubuntu via Vagrant on OSX and start the whole circus running 'vagrant up'

Posted to Jquery Radio buttonset allow deselect over 1 year ago

Great script! Thanks! :D

I don't think chaining has a performance (dis)advantage, but calling multiple times $(this) has. So call as few $(this) as possible: I suggest making a variable, so you have to call $(this) only once, even if you don't like it :p :
var context = $(this)

Posted to See which files are just touched over 1 year ago

Or save this bash script like this somewhere in a bin directory:

!/bin/bash

dir=$1
limit=$2
if [ "$dir" == "" ];then
    dir="$PWD"
fi
if [ "$limit" == "" ];then
    limit="20"
fi

files="$(find $dir -type f -print0 | xargs -0 stat -f "%m%N" | sort -rn | head -$limit)"
files=${files//" "/"\s"}
for i in $files;do
    secs=${i:0:10}
    file=${i:10}
    file=${file#$dir/}
    time_=$(date -r $secs +"%H:%M:%S")
    date=$(date -r $secs +"%y-%m-%d")
    today=$(date +"%y-%m-%d")
    yesterday=$(date -v "-1d" +"%y-%m-%d")
    if [ "$date" == "$today" ];then
        day="Today    "
    elif [ "$date" == "$yesterday" ];then
        day="Yesterday"
    else
        day="$date "
    fi

    echo -e "$day $time_ ${file//"\s"/ }"
    toggle=1
done
Posted to See which files are just touched over 1 year ago

Extra bonus tip: make an alias of it in .bashrc or .zshrc

Achievements
42 Karma
2,757 Total ProTip Views