Created
August 31, 2012 16:18
-
-
Save csu/3555296 to your computer and use it in GitHub Desktop.
Import all txt files in a directory into Day One
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Part of the txt-to-dayone repository: https://github.com/christophersu/txt-to-dayone | |
IFS=$'\n' | |
files=$(ls | egrep '(.txt)') | |
for i in $files; do | |
created=$( GetFileInfo -d "$i" ) | |
dayone -d="$created" new < "$i" | |
done | |
unset IFS |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment