免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
12下一页
最近访问板块 发新帖
查看: 3489 | 回复: 18
打印 上一主题 下一主题

我有一个梦想 [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2010-12-22 12:39 |只看该作者 |倒序浏览
本帖最后由 黑色阳光_cu 于 2010-12-22 12:41 编辑

我有一个梦想,就是shell能更强大点,能用纯shell写程序,什么乱七八糟的外部命令尽量不用,在shell里用awk已是容忍的极限,坚决不在shell里调用perl python什么的编程语言

我喜欢纯粹的东西

论坛徽章:
1
2015年辞旧岁徽章
日期:2015-03-03 16:54:15
2 [报告]
发表于 2010-12-22 12:41 |只看该作者
我也希望,可是,不容易实现。

BUGS
It’s too big and too slow.
There are some subtle differences between bash and traditional versions of sh, mostly because of the
POSIX specification.
Aliases are confusing in some uses.
Shell builtin commands and functions are not stoppable/restartable.
Compound commands and command sequences of the form ‘a ; b ; c’ are not handled gracefully when
process suspension is attempted. When a process is stopped, the shell immediately executes the next com-
mand in the sequence. It suffices to place the sequence of commands between parentheses to force it into a
subshell, which may be stopped as a unit.
Array variables may not (yet) be exported.
There may be only one active coprocess at a time.

论坛徽章:
1
摩羯座
日期:2014-12-29 15:59:36
3 [报告]
发表于 2010-12-22 12:42 |只看该作者
I have a dream

论坛徽章:
0
4 [报告]
发表于 2010-12-22 13:29 |只看该作者
我也想这样,可是不简单啊...

论坛徽章:
145
技术图书徽章
日期:2013-10-01 15:32:13戌狗
日期:2013-10-25 13:31:35金牛座
日期:2013-11-04 16:22:07子鼠
日期:2013-11-18 18:48:57白羊座
日期:2013-11-29 10:09:11狮子座
日期:2013-12-12 09:57:42白羊座
日期:2013-12-24 16:24:46辰龙
日期:2014-01-08 15:26:12技术图书徽章
日期:2014-01-17 13:24:40巳蛇
日期:2014-02-18 14:32:59未羊
日期:2014-02-20 14:12:13白羊座
日期:2014-02-26 12:06:59
5 [报告]
发表于 2010-12-22 16:06 |只看该作者
本帖最后由 jason680 于 2010-12-22 16:40 编辑
我有一个梦想,就是shell能更强大点,能用纯shell写程序,什么乱七八糟的外部命令尽量不用,在shell里用awk ...
黑色阳光_cu 发表于 2010-12-22 12:39


难道你们都不知awk, sed, grep, cut, sort...都是外部指令,就连[ 也是
(就是 if [ ... ] 中的 "[" 也是外部指令)
# which [
/usr/bin/[

因此在不同的Unix中,不一样的环境,不一样指令版本(awk,sed...)
照成同样的脚本,却有不一样的结果.

实在想不透,这样有什么好处呢!!??

论坛徽章:
0
6 [报告]
发表于 2010-12-22 16:32 |只看该作者
用0和1吧

论坛徽章:
0
7 [报告]
发表于 2010-12-22 18:53 |只看该作者
如楼上所说,可以每天0.1.0.1的来回敲阿

论坛徽章:
3
2015年迎新春徽章
日期:2015-03-04 09:56:11数据库技术版块每日发帖之星
日期:2016-08-03 06:20:00数据库技术版块每日发帖之星
日期:2016-08-04 06:20:00
8 [报告]
发表于 2010-12-22 20:40 |只看该作者
这个……没有必要吧,正是有那么多的工具,shell才更加强大啊,awk/sed流也可以,perl流也没问题,管道流都随便你,选择多多啊

论坛徽章:
3
2015年迎新春徽章
日期:2015-03-04 09:56:11数据库技术版块每日发帖之星
日期:2016-08-03 06:20:00数据库技术版块每日发帖之星
日期:2016-08-04 06:20:00
9 [报告]
发表于 2010-12-22 20:41 |只看该作者
光文本文件处理能力而言,awk比纯shell强大多了,sed也很强,但有的时候不方便,结合起来才是最好啊
shell就起调度各个命令的作用,这才是shell最原始的职责

论坛徽章:
0
10 [报告]
发表于 2010-12-22 21:15 |只看该作者
何必呢,各有所长就行了呗。。
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP