GNU parallel won't do what I expect with cat
by lucmove from LinuxQuestions.org on (#57GSX)
fish script (because I love the fish shell):
Code:#!/usr/bin/fish
read input
echo $input >> ./lines.txtcount.txt file:
Code:1
2
3
4
5
6
7
8
9command line:
Code:$ cat count.txt | parallel --pipe -j 4 ./script.fishThe ./lines.txt file is created. I expect it to have all the numbers from 1 to 9, but it only has 1.
What am I doing wrong?
Note: 'read input' in fish shell scripting means read stdin and store it in the $input variable.


Code:#!/usr/bin/fish
read input
echo $input >> ./lines.txtcount.txt file:
Code:1
2
3
4
5
6
7
8
9command line:
Code:$ cat count.txt | parallel --pipe -j 4 ./script.fishThe ./lines.txt file is created. I expect it to have all the numbers from 1 to 9, but it only has 1.
What am I doing wrong?
Note: 'read input' in fish shell scripting means read stdin and store it in the $input variable.