84cc95 Update centos-art.sh script

Authored and Committed by areguera 11 years ago
    Update centos-art.sh script
    
     - Scripts/Bash/Functions/Help/Texinfo/texinfo_updateLicenseLink.sh:
       Remove license files from manual's specific models. These files
       must be symbolic links. Otherwise, the directory structure is
       considered old and a new version must be fetched from central
       repositories.
    
     - Scripts/Bash/Functions/Help/Texinfo/texinfo_updateOutputFiles.sh:
       Move script execution to manuals base directory in order for
       makeinfo to produce content correctly.
    
        
Scripts/Bash/Functions/Help/Texinfo/texinfo_updateLicenseLink.sh CHANGED
@@ -40,9 +40,16 @@ function texinfo_updateLicenseLink {
40
40
# Remove path from license templates.
41
41
FILE=$(basename ${FILE})
42
42
43
- # Remove license files from manual's specific models.
44
- if [[ -e ${MANUAL_BASEDIR_L10N}/${FILE} ]];then
45
- rm -r ${MANUAL_BASEDIR_L10N}/${FILE}
43
+ # Remove license files from manual's specific models. All
44
+ # these files are symbolic links. If they aren't, stop the
45
+ # script execution with an error message. In this case you
46
+ # need to fix your directory structure first (e.g., by
47
+ # fetching a more up-to-date version of it from central
48
+ # repository).
49
+ if [[ -h ${MANUAL_BASEDIR_L10N}/${FILE} ]];then
50
+ rm ${MANUAL_BASEDIR_L10N}/${FILE}
51
+ else
52
+ cli_printMessage "${MANUAL_BASEDIR_L10N} `gettext "has an old directory structure."`" --as-error-line
46
53
fi
47
54
48
55
# Create link from manual's default models to manual's
Scripts/Bash/Functions/Help/Texinfo/texinfo_updateOutputFiles.sh CHANGED
@@ -37,9 +37,11 @@ function texinfo_updateOutputFiles {
37
37
mkdir -p $(dirname $MANUAL_OUTPUT_BASEFILE)
38
38
fi
39
39
40
- # Add the working copy root directory to directory stack to make
41
- # path construction correctly. Otherwise, makeinfo may produce
42
- # paths incorrectly.
40
+ # Move script execution to manuals base directory in order for
41
+ # makeinfo to produce content correctly. This is the location
42
+ # where the documentation's main definition file is stored in.
43
+ # Related content outside this location is accessible through
44
+ # symbolic links.
43
45
pushd ${MANUAL_BASEDIR_L10N} > /dev/null
44
46
45
47
# Verify existence of link to Licenses information.