view admin/diacritical @ 12718:1af86934c14e octave-forge

Make compatible with Octaves new exception-based error handling. Retain compatibility with Octaves old error handling based on error_state. * src/error_helpers.[h,cc]: Added. * src/Makefile.in: Integrate error-helpers.[h,cc]. * src/config.h.in: Added. * configure.ac, src/config.h.in: Test presence of 'error_state' and presence of 'verror (octave_execution_exception&, const char *, va_list)'. * src/__pq_connect__.cc, src/command.cc, src/command.h, src/converters.cc, src/converters_arr_comp.cc, src/pq_connection.cc, src/pq_conninfo.cc, src/pq_exec.cc, src/pq_lo.cc, src/pq_update_types.cc: If necessary, include error-helpers.h, replace error() with c_verror(), set and check a different error indicator than error_state, use CHECK_ERROR or SET_ERR, explicitely check for errors instead of relying on Octave checking error_state when returning to the prompt.
author i7tiol
date Sat, 27 Feb 2016 11:11:04 +0000
parents d67370d6665d
children
line wrap: on
line source

#!/bin/bash
#powered by Jorge Barros de Abreu under GPL
#ficmatin01 at solar dot com dot br
#this script needs "sed" and "mktemp" command and
#translate the common diacritical marks to the texinfo
#format.
ARQ_TMP='mktemp'
if [ $# = 0 ] #testa se nao existe parametro
	then
                echo -e "\n\tScript for diacritical marks in texinfo"
		echo -e "\n\tThis script needs "sed" and "mktemp" command"
		echo -e "\n\tand translate the common diacritical marks to"
		echo -e "\n\tthe texinfo format and needs to be adjusted for"
		echo -e "\n\tyour language."
		echo -e "\n\tThe script base is the structure /�/s/�/@'e/g."
		echo -e "\n\t                                  1   1  2"
		echo
		echo -e "\n\tUp to 1 is the character like is typed in OpenOffice"
		echo -e "\n\tUp to 2 is the same character in texinfo format."
		echo
                echo -e "\tusage: $0 file.texi"
                echo -e "\tthe output overwrite file.texi itself"
                echo
                exit 1
fi
cat $1 | sed "/�/s/�/@'e/g" > $ARQ_TMP
cat $ARQ_TMP | sed "/�/s/�/@'a/g" > $1
cat $1 | sed "/�/s/�/@,{c}/g" > $ARQ_TMP
cat $ARQ_TMP | sed "/�/s/�/@~a/g" > $1
cat $1 | sed "/�/s/�/@'A/g" > $ARQ_TMP
cat $ARQ_TMP | sed "/�/s/�/@\`a/g" > $1
cat $1 | sed "/�/s/�/@\`A/g" > $ARQ_TMP
cat $ARQ_TMP | sed "/�/s/�/@'E/g" > $1
cat $1 | sed "/�/s/�/@'I/g" > $ARQ_TMP
cat $ARQ_TMP | sed "/�/s/�/@'u/g" > $1
cat $1 | sed "/�/s/�/@'U/g" > $ARQ_TMP
cat $ARQ_TMP | sed "/�/s/�/@,{C}/g" > $1
cat $1 | sed "/�/s/�/@~o/g" > $ARQ_TMP
cat $ARQ_TMP | sed "/�/s/�/@~O/g" > $1
cat $1 | sed "/�/s/�/@\"u/g" > $ARQ_TMP
cat $ARQ_TMP | sed "/�/s/�/@\"U/g" > $1
cat $1 | sed "/�/s/�/@~A/g" > $ARQ_TMP
cat $ARQ_TMP | sed "/�/s/�/@'o/g" > $1
cat $1 | sed "/�/s/�/@^E/g" > $ARQ_TMP
cat $ARQ_TMP | sed "/�/s/�/@^e/g" > $1
cat $1 | sed "/�/s/�/@'i/g" > $ARQ_TMP
cat $ARQ_TMP | sed "/�/s/�/@^e/g" > $1
cat $1 | sed "/�/s/�/@^o/g" > $ARQ_TMP
cat $ARQ_TMP | sed "/�/s/�/@^O/g" > $1
rm $ARQ_TMP