You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
# check the directory of append-file(-a) mode, create if not exsit.
195
+
if [ -n"$append_file" ];then
196
+
if [ -e"$append_file" ];then
197
+
[ !-f"$append_file" ] && fatal "Error: $append_file(specified by option -a, for storing run output files) exists but is not a file!"
198
+
[ !-w"$append_file" ] && fatal "Error: file $append_file(specified by option -a, for storing run output files) exists but is not writable!"
199
+
else
200
+
append_file_dir="$(dirname "$append_file")"
201
+
if [ -e"$append_file_dir" ];then
202
+
[ !-d"$append_file_dir" ] && fatal "Error: directory $append_file_dir(specified by option -a, for storing run output files) exists but is not a directory!"
203
+
[ !-w"$append_file_dir" ] && fatal "Error: directory $append_file_dir(specified by option -a, for storing run output files) exists but is not writable!"
204
+
else
205
+
mkdir -p "$append_file_dir"&& fatal "Error: fail to create directory $append_file_dir(specified by option -a, for storing run output files)!"
206
+
fi
207
+
fi
208
+
fi
209
+
210
+
# check jstack-file directory(-S) mode, create directory if not exsit.
192
211
if [ -n"$jstack_file_dir" ];then
193
212
if [ -e"$jstack_file_dir" ];then
194
213
[ !-d"$jstack_file_dir" ] && fatal "Error: $jstack_file_dir(specified by option -S, for storing jstack output files) exists but is not a directory!"
0 commit comments