Oracle Linux xargs Command
来源:互联网 发布:深圳租房 知乎 编辑:程序博客网 时间:2024/06/05 18:47
Xargs reads items from the standard input, delimited by blanks (which can be protected with double or single quotes or a backslash) or newlines, and executes the command (default is /bin/echo) one or more times with any initial-arguments followed by items read from standard input. Blank lines on the standard input are ignored.
-p Prompt the user about whether to run each command line and read a line from the terminal.
-I replace-str Replace occurrences of replace-str in the initial-arguments with names read from standard input. Also, unquoted blanks do not terminate input items; instead the separator is the newline character.
Examples:
List all *.dat files in the current directory and zip each file.
ls *.dat | xargs -I {} zip ./{}.zip {}
Generates a compact listing of all the users on the system.
-p Prompt the user about whether to run each command line and read a line from the terminal.
-I replace-str Replace occurrences of replace-str in the initial-arguments with names read from standard input. Also, unquoted blanks do not terminate input items; instead the separator is the newline character.
Examples:
List all *.dat files in the current directory and zip each file.
ls *.dat | xargs -I {} zip ./{}.zip {}
Generates a compact listing of all the users on the system.
cut -d: -f1 < /etc/passwd | sort | xargs echo
找出所有文件中行数最多的:
ls | xargs -I {} wc -l {} | sort -n | tail -1
0 0
- Oracle Linux xargs Command
- Linux "xargs" command
- Linux command - sed and xargs
- 10 xargs command example in linux
- Xargs Command Examples
- linux xargs
- linux,xargs
- linux xargs
- linux xargs
- linux-xargs
- Linux command line install Oracle Java
- Linux oracle bash: sqlplus: command not found
- linux命令: xargs
- Linux中的xargs命令
- Linux shell: xargs
- linux中的find + xargs
- linux xargs 用法
- Linux xargs命令
- LeetCode | Sudoku Solver
- Sql Server 2008登录失败问题
- 判断字符串内容是否为数字
- Integer与int的区别
- Oracle Linux 6.4配置NFS
- Oracle Linux xargs Command
- Linux awk Tips
- 慎用USES_CONVERSION
- 慎用USES_CONVERSION
- Linux sed Tips
- Linux Ctrl Z
- SELinux tips
- Setting up Samba3.6.9 on Oracle Linux 6
- 关于STL/ATL/WTL之间的区别