在 awk 中调用将记录作为参数的 c 代码

标签 c shell

我想从 awk 中调用 Code.c。请注意,Code.c 将当前记录(即 $0)作为参数。

我是 shell 脚本编写的新手,因此我们将不胜感激。

最诚挚的问候

最佳答案

#!/bin/bash

while read line
do
    para=`echo $line | awk '{print $0}'`
    ./c_code $para
done < your_process_file

关于在 awk 中调用将记录作为参数的 c 代码,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/20141906/

相关文章:

c - 在C中显示文本文件中的文本部分

C泛型类型作为函数参数输入

php - 创建一个 shell 脚本以在 ubuntu 中从 php 运行 sqlite 命令

linux - 如何从 bash shell 获取输出

PHP 转义 shell arg 不需要的行为

c - 从哪里下载Turb​​o或Borland C/C++编译器+ IDE?

C程序打不开文件

c - 奇怪的 C 程序行为

shell - 调整 shell 模式配色方案

c - (Osh) Omake 错误 : Unexpected Token: String: {