Changeset 2141 for palm/trunk/SCRIPTS


Ignore:
Timestamp:
Feb 6, 2017 10:19:32 AM (8 years ago)
Author:
gronemeier
Message:

changed check for existing files at beginning

File:
1 edited

Legend:

Unmodified
Added
Removed
  • palm/trunk/SCRIPTS/mrun

    r1945 r2141  
    2222# Current revisions:
    2323# ------------------
    24 #  
     24# made check for existing files language independent
    2525#
    2626# Former revisions:
     
    12371237
    12381238       # CHECK IF FILE EXISTS
    1239     if [[ $(ls $filename* 2>&1 | grep -c "not found") = 1  || \
    1240           $(ls $filename* 2>&1 | grep -c "nicht gefunden") = 1  || \
    1241           $(ls $filename* 2>&1 | grep -c "No such file") = 1  || \
    1242           $(ls $filename* 2>&1 | grep -c "does not exist") = 1 ]]
     1239    if ! ls $filename* 1>/dev/null 2>&1
    12431240    then
    12441241
     
    13471344       eval filename=${pathout[$i]}/${fname}${endout[$i]}
    13481345       eval catalogname=${pathout[$i]}
    1349        if [[ $(ls $filename* 2>&1 | grep -c "not found") = 1  || \
    1350              $(ls $filename* 2>&1 | grep -c "nicht gefunden") = 1  || \
    1351              $(ls $filename* 2>&1 | grep -c "No such file") = 1  || \
    1352              $(ls $filename* 2>&1 | grep -c "does not exist") = 1 ]]
     1346       if ! ls $filename* 1>/dev/null 2>&1
    13531347       then
    13541348     
Note: See TracChangeset for help on using the changeset viewer.