Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [pipe]

Pipes or named pipes are a feature of the POSIX standard that allow separate processes to communicate with each other without having been designed explicitly to work together.

2
votes
0answers
332 views

In-place delta writes from a pipe

I'm looking for a way to only overwrites the parts of a file that differ from what's supposed to be written to it, so that the file is changed with the least amount of writes to disk possible. My ...
0
votes
1answer
22 views

Named pipe for inter-process communication [on hold]

I want to use a named pipe for communication between a PHP server-script and a service, i.e. a process (a Python script) listening on the other end of the pipe. This service runs intentionally under a ...
0
votes
0answers
21 views

Piping FFMPEG out makes loosing file duration

In order to dynamically encode file and upload them to a server, I output ffmpeg to pipe:1 and use curl to post the result to a file. The problem is when I use MediaInfo to check the file, it appears ...
0
votes
1answer
23 views

Pass cronjob output as parameter to curl

I have cronjob that takes hourly backup. Now I want to pass any stderr to an API. 0 * * * * /usr/local/sbin/script.sh 2>&1 | curl -k -X GET "https://192.168.0.25/path/of/joomla/instance/index....
0
votes
0answers
59 views

using ffmpeg for silence detect with input pipe

I am trying to detect silence from audio file with ffmpeg in c#.i want to pipe input from c# memory stream and get silence duration like following command ffmpeg -hide_banner -i pipe:0 -af ...
0
votes
0answers
12 views

Log watching in less

Let there be a log file, call it /var/log/example. As usual, a service continuously outputs lines to that file. I want to watch this file's contents in real time using less (or equivalent). I am ...
1
vote
2answers
32 views

Use vim in pipeline to dump current line on exit to stdout?

Is it possible for me to do something like this: $ ls | vim | xargs ... and have vim pass to stdout any lines that were visually selected on exit? If it'd be easier to just dump the "current line" ...
2
votes
2answers
102 views

GNU “parallel --pipe” doesn't process stdin by lines

I'm super confused about how to use GNU parallel to pass stdin to the job command. I have what I imagined to be a really common use case. I have some process xxd that does something with stdin and ...
0
votes
1answer
133 views

using xargs pass arguments to sub shell with pipe

I want to rename a number of files. I think I can use xargs to do it. find ./ -name "upload.log-*" ./upload.log-20180622.gz-20180624.gz-20180626.gz ./upload.log-20180624.gz-20180626.gz ./upload.log-...
2
votes
1answer
35 views

Duplicating stderr output and merge with stderr in bash without changing order

I want to write both stderr and stdout to a log file, and print stderr to the terminal (or default output device). Motivation: I have a command in my crontab, and I want to log all of its output to a ...
2
votes
1answer
241 views

How to concatenate two lines with `sed`?

I am trying to concatenate two lines of iwlist output. My grep and sed commands to remove leading and trailing spaces work fine but I can't get the last sed statement to remove the \n to work. What am ...
1
vote
1answer
112 views

Using > and < inside a batch file, with a for loop

When doing this inside a test.bat file: for %%i in (__src\*.js) do jsmin <"%%i" >"temp\%%~ni%%~xi" "(C) Example" I was expecting to see: D:\Temp>jsmin <"__src\background.js" >"temp\...
1
vote
2answers
46 views

Linux bash - how to run a list of binary files that is generated from another script?

I have a script that generates list of binary files to be executed: \home\joe\bin\script1 \home\joe\bin\script2 \home\joe\bin\script3 .. Question 1: How can I run all of these files one by one from ...
1
vote
2answers
4k views

Get response body and show HTTP code by curl

I have endpoint which returns JSON (response body). I need get by curl the response body and process it (for example using jq). It works: response=$(curl -s https://swapi.co/api/people/1/?format=json)...
1
vote
1answer
25 views

How can I use the Linux terminal to pipe only parts of program input concatenated with hard strings?

I understand that I can use xargs like this: echo "-i inputfile.raw -o outputfile.jpg" | xargs -t ./myprogram However, I am fuzz-testing the application and I have a fuzzer which works like this: ...

15 30 50 per page