| 1 | #/usr/bin/ksh | 
|---|
| 2 | # | 
|---|
| 3 | # Script to difference ROPP81 and ROPP90 ROPP PP UGs | 
|---|
| 4 | # | 
|---|
| 5 | # After using this script, users will need to: | 
|---|
| 6 | # 1) Manually fix the monkey business assoc with | 
|---|
| 7 | #   L373 of pp_background.tex: | 
|---|
| 8 | #\begin{eqnarray} | 
|---|
| 9 | #\eta(p,t) = \vv_L \cdot \vu_L - \vv_G \cdot \vu_G = p\dot\theta + } | 
|---|
| 10 | #    (The \end{eqnarray} gets placed there for some reason.) | 
|---|
| 11 | # | 
|---|
| 12 | # 2) Use the old names of the routines at the bottom of romsaf_ropp_ug_pp.tex | 
|---|
| 13 | #\include{pp_phasetobangle} | 
|---|
| 14 | #\include{pp_routines} | 
|---|
| 15 | # | 
|---|
| 16 | # 3) cd $dir81 | 
|---|
| 17 | #    for file in ../common/appendix_use.tex figs/pp_invert_tool_overview.eps pp_background.tex pp_module_files.tex pp_phasetobangle.tex pp_routines.tex romsaf_ropp_ug_pp.tex table_config.tex table_config_ropp4.tex ; do | 
|---|
| 18 | #      svn revert $file | 
|---|
| 19 | #    done | 
|---|
| 20 | #    after you've finished, to restore the pristine $dir81 ROPP PP UG. | 
|---|
| 21 | # | 
|---|
| 22 | # Apart from that, latexdiff does remarkably well with such a complicated | 
|---|
| 23 | # mess of latex files and figures. | 
|---|
| 24 | # | 
|---|
| 25 | # IDC, 26/04/2016 | 
|---|
| 26 |  | 
|---|
| 27 | cd $ROPP_DOC  # trunk | 
|---|
| 28 |  | 
|---|
| 29 |  | 
|---|
| 30 | # One off tex file | 
|---|
| 31 |  | 
|---|
| 32 | dir90=ropp_ug_v90/common | 
|---|
| 33 |  | 
|---|
| 34 | dir81=ropp_ug_v81/common | 
|---|
| 35 |  | 
|---|
| 36 | file=appendix_use.tex | 
|---|
| 37 |  | 
|---|
| 38 | echo "latexdiff $dir81/$file $dir90/$file > $dir81/temp.tex" | 
|---|
| 39 | latexdiff $dir81/$file $dir90/$file > $dir81/temp.tex | 
|---|
| 40 |  | 
|---|
| 41 | echo "mv $dir81/temp.tex $dir81/$file" | 
|---|
| 42 | mv $dir81/temp.tex $dir81/$file | 
|---|
| 43 |  | 
|---|
| 44 |  | 
|---|
| 45 | dir90=ropp_ug_v90/ropp_ug_pp | 
|---|
| 46 |  | 
|---|
| 47 | dir81=ropp_ug_v81/ropp_ug_pp | 
|---|
| 48 |  | 
|---|
| 49 |  | 
|---|
| 50 | # Most tex files | 
|---|
| 51 |  | 
|---|
| 52 | for file in pp_background.tex pp_module_files.tex romsaf_ropp_ug_pp.tex table_config.tex table_config_ropp4.tex ug_pp_intro.tex ; do | 
|---|
| 53 |  | 
|---|
| 54 | echo "latexdiff $dir81/$file $dir90/$file > $dir81/temp.tex" | 
|---|
| 55 | latexdiff $dir81/$file $dir90/$file > $dir81/temp.tex | 
|---|
| 56 |  | 
|---|
| 57 | echo "mv $dir81/temp.tex $dir81/$file" | 
|---|
| 58 | mv $dir81/temp.tex $dir81/$file | 
|---|
| 59 |  | 
|---|
| 60 | done | 
|---|
| 61 |  | 
|---|
| 62 |  | 
|---|
| 63 | # Changed figure | 
|---|
| 64 |  | 
|---|
| 65 | file=figs/pp_invert_tool_overview.eps | 
|---|
| 66 |  | 
|---|
| 67 | echo "cp $dir90/$file $dir81/$file" | 
|---|
| 68 | cp $dir90/$file $dir81/$file | 
|---|
| 69 |  | 
|---|
| 70 |  | 
|---|
| 71 | # Renamed files (1) | 
|---|
| 72 |  | 
|---|
| 73 | file90=pp_phase2bangle.tex | 
|---|
| 74 | file81=pp_phasetobangle.tex | 
|---|
| 75 |  | 
|---|
| 76 | echo "latexdiff $dir81/$file81 $dir90/$file90 > $dir81/temp.tex" | 
|---|
| 77 | latexdiff $dir81/$file81 $dir90/$file90 > $dir81/temp.tex | 
|---|
| 78 |  | 
|---|
| 79 | echo "mv $dir81/temp.tex $dir81/$file81" | 
|---|
| 80 | mv $dir81/temp.tex $dir81/$file81 | 
|---|
| 81 |  | 
|---|
| 82 |  | 
|---|
| 83 | # Renamed files (2) | 
|---|
| 84 |  | 
|---|
| 85 | file90=pp_bangle2refrac.tex | 
|---|
| 86 | file81=pp_routines.tex | 
|---|
| 87 |  | 
|---|
| 88 | echo "latexdiff $dir81/$file81 $dir90/$file90 > $dir81/temp.tex" | 
|---|
| 89 | latexdiff $dir81/$file81 $dir90/$file90 > $dir81/temp.tex | 
|---|
| 90 |  | 
|---|
| 91 | echo "mv $dir81/temp.tex $dir81/$file81" | 
|---|
| 92 | mv $dir81/temp.tex $dir81/$file81 | 
|---|
| 93 |  | 
|---|