?? fail-diag
字號(hào):
#!/bin/sh# make sure touch gives reasonable diagnosticsif test "$VERBOSE" = yes; then set -x touch --versionfi. $srcdir/../envvar-check. $srcdir/../lang-defaultPRIV_CHECK_ARG=require-non-root . $srcdir/../priv-checkpwd=`pwd`tmp=fail-diag.$$trap 'status=$?; cd $pwd; rm -rf $tmp && exit $status' 0trap '(exit $?); exit' 1 2 13 15framework_failure=0mkdir $tmp || framework_failure=1cd $tmp || framework_failure=1if test $framework_failure = 1; then echo 'failure in testing framework' 1>&2 (exit 1); exitfifail=0# Before fileutils-4.1, we'd get the following misleading# diagnostic instead of `Permission denied'.# touch: creating `/': Is a directorytouch / > out 2>&1 && fail=1touch /no/such-dir >> out 2>&1 && fail=1# On SunOS4, EPERM is `Not owner'.# On some *BSD systems it's `Operation not permitted'.for msg in 'Not owner' 'Operation not permitted' 'Permission denied'; do cat > exp <<EOF touch: setting times of \`/': $msg touch: creating \`/no/such-dir': No such file or directoryEOF cmp out exp > /dev/null 2>&1 && breakdonetest $fail = 1 && diff out exp 2> /dev/null(exit $fail); exit
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號(hào)
Ctrl + =
減小字號(hào)
Ctrl + -