diff options
Diffstat (limited to 'add_to_index.sh')
-rwxr-xr-x | add_to_index.sh | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/add_to_index.sh b/add_to_index.sh new file mode 100755 index 0000000..dacdf35 --- /dev/null +++ b/add_to_index.sh @@ -0,0 +1,7 @@ +#!/bin/sh +cd $HOME/www/blogposts +FILE=$(basename $1|sed s/.txt/.html/) +echo $FILE +/home/void/www/sh/formatter.sh /home/void/www/blogposts/$(basename $1) >| "$HOME/www/source/$FILE" +sed -i "/\<ul name=blogposts\>/s/$/\n\t\<li\>\<a href=\"$FILE\"\>$FILE\<\/a\>\<\/li\>/" $HOME/www/source/index.html + |