# HG changeset patch # User Oleksandr Gavenko # Date 1455974424 -7200 # Node ID da0024f4f068f84a400d2e49ea4e74805c634f5f # Parent 158115e70f3dcd1b4b4ac782769941487cfaf969 Remove frame based publishing, stick to iframe. Clean CHM code generation. diff -r 158115e70f3d -r da0024f4f068 Makefile --- a/Makefile Sat Feb 20 14:43:09 2016 +0200 +++ b/Makefile Sat Feb 20 15:20:24 2016 +0200 @@ -46,7 +46,7 @@ HTML_DIR := tips-html RST_HTML_FILES := $(patsubst %.rst,$(HTML_DIR)/%.html,$(RST_FILES)) HTML_FILES := $(RST_HTML_FILES) \ - $(HTML_DIR)/index.html $(HTML_DIR)/iframe.html $(HTML_DIR)/frame.html $(HTML_DIR)/frame-index.html + $(HTML_DIR)/index.html $(HTML_DIR)/iframe.html TXT__FILES := $(addprefix $(HTML_DIR)/,$(TXT_FILES)) CHM_FILES := $(addprefix $(HTML_DIR)/,chm.hhp chm.hhc chm.stp) @@ -68,7 +68,7 @@ .PHONY: deploy deploy: deploy2defun-web deploy2defun-hg deploy2sf-web deploy2sf-hg -# Will be accessible via: http://tips.defun.work/frame.html +# Will be accessible via: http://tips.defun.work/ .PHONY: deploy2defun-web deploy2defun-web: html rsync --delete -avP -e ssh tips-html/ $(WWW_SRV_USER)@$(WWW_SRV_NAME):/srv/www/tips/ @@ -77,7 +77,7 @@ deploy2defun-hg: hg push ssh://$(HG_SRV_USER)@$(HG_SRV_NAME)//srv/hg/tips || [ $$? = 1 ] -# Will be accessible via: http://gavenkoa.users.sourceforge.net/tips-html/frame.html +# Will be accessible via: http://gavenkoa.users.sourceforge.net/tips-html/ .PHONY: deploy2sf-web deploy2sf-web: html rsync --delete -avP -e ssh tips-html/ gavenkoa@frs.sourceforge.net:/home/user-web/g/ga/gavenkoa/htdocs/tips-html/ @@ -106,7 +106,7 @@ echo ''; \ echo ''; \ @@ -132,9 +132,6 @@ echo ' Written by Oleksandr Gavenko (AKA gavenkoa), compiled at ``'`date +%F`'`` from rev ``'`hg id -i`'``.'; \ } >$@ -$(HTML_DIR)/frame-index.html: index.sh $(RST_HTML_FILES) $(MAKEFILE_LIST) | $(HTML_DIR) - ./index.sh frame >$@ - $(HTML_DIR)/index.html: $(HTML_DIR)/README.html $(MAKEFILE_LIST) | $(HTML_DIR) cp $< $@ @@ -145,7 +142,7 @@ cp $< $@ .PHONY: chm -chm: html $(CHM_FILES) $(HTML_DIR)/index-chm.html +chm: html $(CHM_FILES) $(HTML_DIR)/iframe.html cd $(HTML_DIR); for file in *.html; do sed -i '/<\?xml.*\?>/d' $$file; done $(HTML_DIR)/%.stp: %.stp $(MAKEFILE_LIST) | $(HTML_DIR) @@ -157,9 +154,6 @@ $(HTML_DIR)/chm.hhc: chm-hhc.sh $(MAKEFILE_LIST) | $(HTML_DIR) ./chm-hhc.sh >$@ -$(HTML_DIR)/index-chm.html: index.sh $(MAKEFILE_LIST) | $(HTML_DIR) - ./index.sh html >$@ - ################################################################ # Init targets. diff -r 158115e70f3d -r da0024f4f068 chm-hhc.sh --- a/chm-hhc.sh Sat Feb 20 14:43:09 2016 +0200 +++ b/chm-hhc.sh Sat Feb 20 15:20:24 2016 +0200 @@ -12,10 +12,13 @@ echo '
  • ' echo ' ' -echo ' \n' +echo ' \n' echo ' ' for file in *.rst *.txt; do + case $file in + HEADER.rst) continue;; + esac ext=${file##*.} name=${file%.${ext}} echo '
  • ' diff -r 158115e70f3d -r da0024f4f068 chm-hhp.sh --- a/chm-hhp.sh Sat Feb 20 14:43:09 2016 +0200 +++ b/chm-hhp.sh Sat Feb 20 15:20:24 2016 +0200 @@ -2,10 +2,10 @@ echo '[OPTIONS]' echo 'Compatibility=1.1 or later' -echo 'Compiled file=tips4gavenkoa.chm' +echo 'Compiled file=chm.chm' echo 'Contents file=chm.hhc' echo 'Default Window=Navigation panel' -echo 'Default topic=index-chm.html' +echo 'Default topic=iframe.html' echo 'Display compile progress=No' echo 'Full text search stop list file=chm.stp' echo 'Full-text search=Yes' @@ -13,11 +13,14 @@ echo 'Title=Tips from gavenkoa' echo '' echo '[WINDOWS]' -echo 'Navigation panel=,"chm.hhc",,"index-chm.html","index-chm.html",,,,,0x62520,250,0x304e,[0,0,900,600],,,,,,,0' +echo 'Navigation panel=,"chm.hhc",,"iframe.html","iframe.html",,,,,0x62520,250,0x304e,[0,0,900,600],,,,,,,0' echo '' echo '[FILES]' for file in *.rst *.txt; do + case $file in + HEADER.rst) continue;; + esac ext=${file##*.} name=${file%.${ext}} case $ext in @@ -29,7 +32,6 @@ ;; esac done -echo index-chm.html echo '' echo '[INFOTYPES]' diff -r 158115e70f3d -r da0024f4f068 frame.html --- a/frame.html Sat Feb 20 14:43:09 2016 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,10 +0,0 @@ - - - - tips index - - - - - - diff -r 158115e70f3d -r da0024f4f068 index.sh --- a/index.sh Sat Feb 20 14:43:09 2016 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,42 +0,0 @@ -#!/bin/sh - -cat < - - - Tips - - - -

    Tips

    -
      -EOF - -for file in *.rst *.txt; do - case $file in - HEADER.rst) continue; - esac - ext=${file##*.} - [ "$ext" = "rst" ] && ext=html - name=${file%.*} - case "$1" in - html) echo "
    • $name" ;; - frame) echo "
    • $name" ;; - *) exit 1 ;; - esac -done - -cat < -
      - Oleksandr Gavenko -
      - - -EOF