How to use “cat” command on “find” command's output?
You can do this with find
alone using the -exec
action:
find /location -size 1033c -exec cat {} +
{}
will be expanded to the files found and +
will enable us to read as many arguments as possible per invocation of cat
, as cat can take multiple arguments.
If your find
does not have the +
extension or you want to read the files one by one:
find /location -size 1033c -exec cat {} \;
If you want to use any options of cat
, do:
find /location -size 1033c -exec cat -n {} +
find /location -size 1033c -exec cat -n {} \;
How to use “cat” command on “find” command's output?的更多相关文章
- 解决xcode10打包报错:That command depends on command in Target ‘xxx’:scrpit phase"[CP] Copy Pods Resources"
问题:使用xcode10打包报错,提示 error:Multiple commands produce ‘xxxx/xxx.app’ 1)Target ‘xx’ has create director ...
- 【Linux】-NO.8.Linux.4.Command.1.001-【Common Command】-
1.0.0 Summary Tittle:[Linux]-NO.8.Linux.4.Command.1.001-[Common Command]- Style:Linux Series:Command ...
- 在cmd窗口输入命令遇到You must run this command from a command prompt with administrator privilege怎么办?
点开始菜单,找到Accessories(附件),找到Command Prompt窗口,点右键,选“run as administrator”(以管理员身份运行),之后再执行先前的命令就好了. 2017 ...
- 【D3D12学习手记】The Command Queue and Command Lists
GPU有一个命令队列,CPU通过Direct3D API将命令提交到队列里来使用命令列表(command lists),如下图.当一套命令(a set of commands)已经被提交到命令队列,他 ...
- command > /dev/null command > /dev/null 2>&1nohup command &> /dev/null的区别
1.对以下命令进行依次区分 command 执行一条普通的命令 command > /dev/null '>'表示将标准输出重定向 '>>'表示追加,/dev/null是一 ...
- 13 Basic Cat Command Examples in Linux(转) Linux中cat命令的13中基本用法
Cat (串联) 命令是Linux/Unix开源系统中比较常用的一个命令.我们可以通过Cat命令创建一个或多个文件,查看文件内容,串联文件并将内容输出到终端设备或新的文件当中,这篇文章我们将会以实例的 ...
- 13 Basic Cat Command Examples in Linux
FROM: http://www.tecmint.com/13-basic-cat-command-examples-in-linux/ The cat (short for “concatenate ...
- Top 30 Nmap Command Examples For Sys/Network Admins
Nmap is short for Network Mapper. It is an open source security tool for network exploration, securi ...
- 15 Examples To Master Linux Command Line History
When you are using Linux command line frequently, using the history effectively can be a major produ ...
随机推荐
- 12.vue属性.监听.组件
1.计算属性 https://cn.vuejs.org/v2/guide/computed.html new Vue({ computed:{//定义 show(){ } } }) ++计算属性1.h ...
- 脚本一键部署lnmp
[root@ycj ~]# wget -c http://soft.vpser.net/lnmp/lnmp1.1-full.tar.gz && tar zxf lnmp1.1-full ...
- itoa()、atoi()、任意进制转换
头文件:<stdlib.h> itoa --功能:将任意类型的数字转换为字符串.在<stdlib.h>中与之有相反功能的函数是atoi. atoi----功 能: 将字符串转换 ...
- PAT甲级1080 Graduate Admission【模拟】
题目:https://pintia.cn/problem-sets/994805342720868352/problems/994805387268571136 题意: 模拟高考志愿录取. 考生根据总 ...
- 2018-2019-2 20175320实验一《Java开发环境的熟悉》实验报告
2018-2019-2 20175320实验一<Java开发环境的熟悉>实验报告 一.实验步骤及内容 (一)带包程序的编译运行 1.使用mkdir命令创建如图所示目录 2.进入exp1下的 ...
- Spring Enable* 注解
Spring提供了一系列以Enable开头的注解,这些注解本质上是激活Spring的某些管理功能.比如,EnableWebMvc. 这个注解引入了MVC框架在Spring 应用中需要用到的所有bean ...
- LeetCode 237 Delete Node in a Linked List 解题报告
题目要求 Write a function to delete a node (except the tail) in a singly linked list, given only access ...
- STL库学习笔记(待补充QAQ
几百年前就说要学STL了然后现在还没动呢QAQ总算还是克服了懒癌决定学下QAQ 首先港下有哪几个vector listset map stack queue,大概就这些? 然后因为有几个基本操作每个都 ...
- Cutterman - 最好用的切图工具
Cutterman - 最好用的切图工具 http://www.cutterman.cn/zh/cutterman
- WIN7搭建ASP站点
在WIN7配置IIS用于搭建ASP站点(非ASP.NET) ,仅安装.配置必要文件. 1.安装IIS管理工具,用于支持静态页面. 2.添加匿名访问权限. 搭建站点指定到特定文件夹,浏览静态页面会报如下 ...