Redirections and pipes.
Pipex is a program that replicates the behavior of doing < infile cmd1 | cmd2 > outfile in bash, or even < infile cmd1 | ... | cmdn > outfile.
The program will receive al least 4 arguments where the first one will be the input file from it will read, and the last one will be the output file that will contain the final outputs.
./pipex infile cmd1 cmd2 cmd3 outfileSee the wiki for documentation.
Clone the project
git clone --recursive [email protected]:Aryalexa/42-pipex.gitCompile the files and generate the pipex executable.
makeExamples of usage:
./pipex infile "ls -l" "wc -l" outfile
./pipex infile "grep a1" "wc -w" outfile