1
for i in *.org; do sed '/^#+title.*/a #+date=`basename $i .org`' $i; done
This will append the basename after each line containing #+title.
basename
#+title
prev post next post