⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 do_demo

📁 speech signal process tools
💻
字号:
#! /bin/sh# @(#)do_demo	1.7 11/5/91 ERL# This script starts up a specific demo.  A crude file locking # technique is used to reduce the probability that more than one# demo is run at the same time.  NOTE: the existence and name of # this lock file is also exploited in the script edemos.sh# Arguments:#           $1 = temp directory#           $2 = demo directorydemo_temp=$1demo_dir=$2# create temp directory if necessary, check that it is writableif test ! -d $demo_tempthen  mkdir $demo_temp 2> /dev/nullfitouch $demo_temp/foo.$$ 2> /dev/nullif test -f $demo_temp/foo.$$ then   rm $demo_temp/foo.$$ else    echo "$0($2): can't create $demo_temp or can't write in it; exiting. "   exit 1fi# check demo lock filelockfile=$demo_temp/demo.lockmessage=$demo_temp/errormessif [ -f $lockfile ]; thenrm -f $messagecat > $message << EOFCannot run $demo_dir demo because it appears that another demo is running.If not, then please "rm $lockfile".EOF  xtext -Wp 0 0 -t "DEMO ERROR" -F $message &  exit 1fi# Some demos require that scripts know where the temp directory is# so we put its name in a temp file in the user's home directoryrm -f $HOME/.demo_tempecho $demo_temp > $HOME/.demo_temp# Now, we create the lockfile and invoke the demotouch $lockfilecd $demo_direcho ""echo "Running Entropic demo: $demo_dir"./rundemo $demo_temprm -f $lockfile

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -