Skip to content

Instantly share code, notes, and snippets.

@kmmbvnr
Created October 18, 2016 07:19
Show Gist options
  • Save kmmbvnr/0c55b60c6383117d1eae17a3a4432174 to your computer and use it in GitHub Desktop.
Save kmmbvnr/0c55b60c6383117d1eae17a3a4432174 to your computer and use it in GitHub Desktop.
#!/bin/bash
DWDIR=~/Downloads/`date +%Y-%m-%d`
if [ ! -d $DWDIR ]; then
cd ~/Downloads/ && find -maxdepth 1 -type d -empty -delete
mkdir $DWDIR
unlink ~/Downloads/Current
ln -sf $DWDIR ~/Downloads/Current
fi;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment