comparison website/www/Makefile @ 6763:d93b441ee778

Handle build issues, update css for mobile I added www.roundup-tracker.org as a property of mine in google search console. It reports bad mobile experience. According to the goatcounter tracker I put in, we get 400 hits from phones/small tablets; 400 from tablets/small laptops and 800 from computer screens. So 1/4 is mobile and 1/2 is not a large computer screen. On mobile (<960px) the left hand menu is stacked on top of the column in mobile sizes. Sub-menu links are spaced apart to make them easier to clkick on with a finger. Same with the table of contents in the documents. The main document content is now full display width (rather than scrunched to the right side of the display). This is just a quick hack, but it should make the docs more usable. As I worked, I found that _static/style.css changes were not being copied into the html build directory when sphinx was rerun. Nuke entire html subdir and rebuild from scratch each time. Also added comments to Makefile. Also robots.txt was being added as extra_html by sphinx, but it causes a missing from TOC error that exits the build (when using -W). Since exiting on warning is better, I changed Makefile to add robots.txt. Removed robots.txt references from conf.py.
author John Rouillard <rouilj@ieee.org>
date Sun, 10 Jul 2022 18:16:13 -0400
parents 4eee1aa1103e
children 075a2f6d703b
comparison
equal deleted inserted replaced
6762:f8ee14436371 6763:d93b441ee778
17 17
18 # after upgrade to sphinx 1.8.5, search.html is missing load of searchtools. 18 # after upgrade to sphinx 1.8.5, search.html is missing load of searchtools.
19 # fix that in postprocess 19 # fix that in postprocess
20 # also sed index.html to properly format meta og:... entries. 20 # also sed index.html to properly format meta og:... entries.
21 html: docs 21 html: docs
22 rm -rf html
22 mkdir -p $(TMP)/doctrees $(HTML) 23 mkdir -p $(TMP)/doctrees $(HTML)
23 sphinx-build -n -W -b html -d $(TMP)/doctrees . $(HTML) 24 sphinx-build -n -W -b html -d $(TMP)/doctrees . $(HTML)
25 # install searchtools.js into search page.
24 grep 'searchtools.js' html/search.html || sed -i -e '/language_data.js/s#</script>#</script>\n <script type="text/javascript" src="_static/searchtools.js"></script>#' html/search.html 26 grep 'searchtools.js' html/search.html || sed -i -e '/language_data.js/s#</script>#</script>\n <script type="text/javascript" src="_static/searchtools.js"></script>#' html/search.html
27 # sphinx inserts \: for : in meta tags. Get rid of the \ in
28 # opengraph tags
25 sed -i -e '/<meta/s/og\\:/og:/' html/index.html 29 sed -i -e '/<meta/s/og\\:/og:/' html/index.html
30 cp robots.txt html/robots.txt
26 31
27 linkcheck: 32 linkcheck:
28 mkdir -p $(TMP)/linkcheck $(TMP)/doctrees 33 mkdir -p $(TMP)/linkcheck $(TMP)/doctrees
29 sphinx-build -b linkcheck -d $(TMP)/doctrees . $(TMP)/linkcheck 34 sphinx-build -b linkcheck -d $(TMP)/doctrees . $(TMP)/linkcheck
30 @echo 35 @echo

Roundup Issue Tracker: http://roundup-tracker.org/