Utensil's Zettelkasten-style forest of evergreen notes on math and tech. utensil.tngl.sh/forest/
0

Configure Feed

Select the types of activity you want to include in your feed.

Fix build_changed for xml2html

author
utensil
date (Sep 9, 2025, 8:49 PM +0800) commit 0d2bcb10 parent 3cf29474 change-id rwvzpmtq
+9 -6
+7 -4
build_changed.sh
··· 8 8 9 9 echo "TEXINPUTS=$TEXINPUTS" 10 10 11 + source convert_xml.sh 12 + 11 13 function relative_to_project_root() { 12 14 local target=$1 13 15 local common_part=$PROJECT_ROOT ··· 42 44 just copy "$CHANGED_FILE_RELATIVE" 43 45 elif [[ $CHANGED_FILE == *".tree" ]]; then 44 46 just forest 47 + # only convert the modified tree's xml to html 48 + # do not take affected trees into account, for now 49 + convert_xml_to_html "./output/forest/${CHANGED_FILE_BASENAME%.*}/index.xml" 45 50 elif [[ $CHANGED_FILE == *".tex" ]]; then 46 51 # even with full rebuild, updates to preambles are NOT reflected 47 52 # ./build.sh ··· 64 69 65 70 touch build/live/trigger.txt 66 71 67 - source convert_xml.sh 68 - 69 72 # Post-process: Convert HTML files for tree or XSL changes 70 73 if [[ $CHANGED_FILE == *".xsl" ]]; then 71 74 XSL_CHANGED=1 convert_xml_files true 72 - elif [[ $CHANGED_FILE == *".tree" ]]; then 73 - convert_xml_files true 75 + # elif [[ $CHANGED_FILE == *".tree" ]]; then 76 + # convert_xml_files true 74 77 fi 75 78
+2 -2
convert_xml.sh
··· 2 2 # set -e 3 3 4 4 OUT_DIR=output/forest 5 - XSL_FILE=$OUT_DIR/default.xsl 6 - # XSL_FILE=$OUT_DIR/uts-forest.xsl 5 + # XSL_FILE=$OUT_DIR/default.xsl 6 + XSL_FILE=$OUT_DIR/uts-forest.xsl 7 7 8 8 function convert_xml_to_html() { 9 9 local xml_file=$1