| #!/bin/bash |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| function texinfo_deleteCrossReferences { |
| |
| local -a PATTERN |
| local -a REPLACE |
| |
| |
| local MANUAL_ENTRY="$1" |
| |
| |
| |
| if [[ $MANUAL_ENTRY == '' ]];then |
| cli_printMessage "`gettext "The first positional parameter cannot be empty."`" --as-error-line |
| fi |
| |
| |
| local NODE="$(texinfo_getEntryNode "$MANUAL_ENTRY")" |
| |
| |
| |
| PATTERN[0]="@(pxref|xref|ref)\{(${NODE})\}" |
| REPLACE[0]='--- @strong{'`gettext "Removed"`'}(\1:\2) ---' |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| PATTERN[1]="^(\* ${NODE}:(.*):(.*))$" |
| REPLACE[1]='\@comment --- '`gettext "Removed"`'(\1) ---' |
| |
| |
| local MANUAL_ENTRIES=$(cli_getFilesList ${MANUAL_BASEDIR_L10N} \ |
| --pattern=".+\.${MANUAL_EXTENSION}") |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| sed -r -i ":a;N;s!${PATTERN[0]}!${REPLACE[0]}!g;ba" ${MANUAL_ENTRIES} |
| |
| |
| |
| |
| sed -r -i "s!${PATTERN[1]}!${REPLACE[1]}!" ${MANUAL_ENTRIES} |
| |
| } |