Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 4 additions & 7 deletions export_settings.sh
Original file line number Diff line number Diff line change
@@ -1,23 +1,20 @@
#!/bin/bash

# this will read all html files and replace dj-* attributes with django code
# YOU MAY NEED TO copy the python export.py script to the same folder as where BSS app image is located

logfile="/tmp/bss_export.log"
cwd=`pwd`
export_script=$(realpath export.py)

cd $1

# if you have a venv setup, replace the following
source ~/venv/django-bss-tools/bin/activate

echo "run at `date`" >> $logfile
echo "`which python3`" >> $logfile
echo $cwd >> $logfile
echo $1 >> $logfile
pushd $1
for f in *.html
do
echo python3 $cwd/export.py $f >> $logfile
python3 $cwd/export.py $f
python3 $export_script $f
done
popd