摘要:grep -v -f b.txt a.txt并集:cat a.txt b.txt | sort | uniq 交集:cat a.txt b.txt | sort | uniq -d 删除交集:cat a.txt b.txt | sort | uniq -u并集:comm -2 a.txt b.txt 交集:comm -1 a.txt b.txt 删除交集:comm -3 a.txt b.txt......
摘要:fcitx 安装时应该注意的问题 下载的软件包,有两种格式,一种是rpm,一种是tar.gz,我们分别来说怎样安装。 如果下载的是rpm,安装简单一些。可以直接在资源管理器里面点击它,一般会弹出软件包管理器的安装程序,一路确定就行了。如果这样不行,就打开一个终端,用命令来安装: rpm -ivh ebf-fcitx-<版本号>.i386.rpm 如果曾经安装过相......
sed 编辑器手册上一页 ...the wolf cubs will meet on tuesday after school$ 【程序编程相关:
《利用Tripwire检测系统的完整性(】 【推荐阅读:
技巧:像执行命令一样执行你的脚本】 【扩展信息:
《利用Tripwire检测系统完整性(1】 注意如果输入是源自之前的命令输出,则不需要指定文件名—同样的原则也适用于 awk.sort 与其它大多数 linux\unix 命令行实用工具程序. 多次修改 如果需要对同一文件或行作多次修改,可以有三种方法来实现它.第一种是使用 "-e" 选项,它通知程序使用了多条编辑命令.例如: $ echo the tiger cubs will meet on tuesday after school | sed -e s/tiger/wolf/ -e s/after/before/ the wolf cubs will meet on tuesday before school $ 这是实现它的非常复杂的方法,因此 "-e" 选项不常被大范围使用.更好的方法是用分号来分隔命令: $ echo the tiger cubs will meet on tuesday after school | sed s/tiger/wolf/; s/after/before/ the wolf cubs will meet on tuesday before school $ 注意分号必须是紧跟斜线之后的下一个字符.如果两者之间有一个空格,操作将不能成功完成,并返回一条错误消息.这两种方法都很好,但许多管理员更喜欢另一种方法.要注意的一个关键问题是,两个撇号 ( ) 之间的全部内容都被解释为 sed 命令.直到您输入了第二个撇号,读入这些命令的 shell 程序才会认为您完成了输入.这意味着可以在多行上输入命令—同时 linux 将提示符从 ps1 变为一个延续提示符(通常为 ">")—直到输入了第二个撇号.一旦输入了第二个撇号,并且按下了 enter 键,则处理就进行并产生相同的结果,如下所示: $ echo the tiger cubs will meet on tuesday after school | sed > s/tiger/wolf/ > s/after/before/ the wolf cubs will meet on tuesday before school $ 全局修改 让我们开始一次看似简单的编辑.假定在要修改的消息中出现了多次要修改的项目.默认方式下,结果可能与预期的有所不同,如下所示: $ echo the tiger cubs will meet this tuesday at the same time as the meeting last tuesday | sed s/tuesday/thursday/ the tiger cubs will meet this thursday at the same time as the meeting last tuesday $ 与将出现的每个 "tuesday" 修改为 "thursday" 相反,sed 编辑器在找到一个要修改的项目并作了修改之后继续处理下一行,而不读整行.sed 命令功能大体上类似于替换命令,这意味着它们都处理每一行中出现的第一个选定序列.为了替换出现的每一个项目,在同一行中出现多个要替换的项目的情况下,您必须指定在全局进行该操作: $ echo the tiger cubs will meet this tuesday at the same time as the meeting last tuesday | sed s/tuesday/thursday/g the tiger cubs will meet this thursday at the same time as the meeting last thursday $ ...
下一页 摘要:list of additional sccs commandslist of additional sccs commandsattention: using non-sccs commands with sccs files can damage the sccs files. the following sccs commands complete the system for handli......