0
点赞
收藏
分享

微信扫一扫

Linux的常用命令记录grep以及】sudo make uninstall&make install

快乐与微笑的淘气 2022-04-15 阅读 54

1.、进入工程目录下,linux安装命令为sudo make install;

2.进入工程目录下,linux的卸载命令为sudo make uninstall;

3.grep命令的基本概念和用途

grep命令是linux中一种强大的文本搜索工具,它能使用正则表达式搜索文本,并把匹配的行打印出来。
在一个或多个文件中搜素字符串模式,如果字符串模式包括空格,也必须被引用,模式后的所有字符串被看作文件名。搜索的结果被送到标准输出(stdout),不影响原文件内容。

(1)案例一

grep [option] pattern files

主要选项[option]说明及示例:
-c : 只输出匹配行的计数

[lsh@bogon helloworld]$ cat -n helloworld.c
     1    #include<stdio.h>
     2    int main()
     3    {
     4        printf("hello study automake configure&makefile progress...LSHTest..");
     5        printf("hello study automake configure&makefile progress...LSHTest..");printf("hello");
     6        return 0;
     7    }
     8    
[lsh@bogon helloworld]$ grep -c "print"

举报

相关推荐

0 条评论