tcsh 中的数字范围
假设我有一堆文件,它们的名称包含一个数字,如下所示: xxx_1.txt, xxx_2.txt, ... xxx_42.txt
在 bash 中,很容易对这些文件的子集进行操作,例如 ls xxx_{1..33}.txt xxx_{35..41}
。
与此类似的 tcsh 是什么?
Suppose I have a bunch of files, the names of which contain a number, like this: xxx_1.txt, xxx_2.txt, ... xxx_42.txt
In bash, it's easy to operate on subsets of these files, e.g. ls xxx_{1..33}.txt xxx_{35..41}
.
What would be the tcsh analog of this?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
据我所知,tcsh 中没有内置机制来指定范围模式(单字符范围除外)。但是,例如,您可以将
seq
实用程序(如果可用)与sed
一起使用:As far as I know there is no built-in mechanism to specify range patterns (except single character ranges) in
tcsh
. But you could, for example, use theseq
utility (if it is available) together withsed
: