sbib improve and rg bool

This commit is contained in:
ackman678
2023-05-15 10:49:24 -04:00
parent 26d1974906
commit d328524cd9
14 changed files with 171 additions and 52 deletions

View File

@@ -15,6 +15,9 @@ set -e
appPath="$HOME/projects/dev/reveal.js"
portNumber=${2:-8000}
fn=$1 #markdown document to render e.g. neuroanatomy1.md
basefn=$(basename $fn)
fullfn=$(realpath $fn)
if [[ ! -d $appPath ]]; then
echo "reveal.js not found"
@@ -23,13 +26,10 @@ else
cd $appPath
fi
fn=$1 #markdown document to render e.g. neuroanatomy1.md
basefn=$(basename $fn)
if [[ ! -e $basefn ]]; then
ln -s $fn $basefn
ln -s $fullfn $basefn
fi
#add markdown filename into html title tag
fn2=$(echo $basefn | sed -E 's/[0-9]{2,4}-//g' | sed 's/\.md//') #prep filename
sed -i -E "s|(<title>).+(<\/title>)|\1$fn2\2|" index.html #swap in document title