摘要:
我学习编写了一个shell,在运行一部分后提示如下:
syntax error at line 255:end of file unexpected
我的shell只有254行,检查了很多遍循环和判断语句没有发现什么错错误
怎么办?有什么方法可以快速查出编写的shell到底错在哪吗?
waker 回复于:2005-07-22 16:40:36
dos2unix 一下再......
摘要:
[code:1:1b5d7444d4]1、使用一系列圆点来指示进度
--------后台循环------------
#!/bin/bash
while true
do
echo -e ".\c"
sleep 3
done &
bg_pid=$!
./test.sh
kill -9 $bg_pid
-----------后台函数---------
#!/bi......
双引号前的$是什么意思
man bash, 找到 quoting 那段說明:
【程序编程相关:
AboutFish】 【推荐阅读:
3D游戏引擎设计与实现(17)】
【扩展信息:
3D游戏引擎设计与实现(18)】 words of the form $string are treated specially. the word expands to
string, with backslash-escaped characters replaced as specifed by the
ansi c standard. backslash escape sequences, if present, are decoded
as follows:
\a alert (bell)
\b backspace
\e an escape character
\f form feed
...
下一页 摘要:
################################################################
#[0]: 基础 #
################################################################
**sed执行过程:
a. 如果已到达文件尾,goto e;否则,用当前行内容替换模式空间的内容(即缓......