Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/vinicius-santoro/42-formation-lvl1-6.pipex

Project 6: pipex - Sixth project for the formation of software engineers at school 42 São Paulo.
https://github.com/vinicius-santoro/42-formation-lvl1-6.pipex

Last synced: 16 days ago
JSON representation

Project 6: pipex - Sixth project for the formation of software engineers at school 42 São Paulo.

Awesome Lists containing this project

README

        

# 42-formation-lvl1-6.pipex

### _Project 6: pipex - Sixth project for the formation of software engineers at school 42 São Paulo._

- This project aims to recreate the Unix pipe ( | ) command.

## _This project was like this:_

![pipex](https://user-images.githubusercontent.com/83036509/154865901-1208e1a5-4b7a-4e8c-aba1-f49e4a5d2133.gif)

## _How to test it_

For you to test this project, you should use the following way:

```bash
./pipex file1 "cmd1" "cmd2" file2
```
Just in case: file1 and file2 are file names, cmd1 and cmd2 are shell commands with their parameters.

The execution of the pipex program should do the same as the next shell command:

```bash
< file1 cmd1 | cmd2 > file2
```

Example 1:
```bash
./pipex infile "ls -l" "wc -l" outfile
```
Should be the same as:
```bash
< infile ls -l | wc -l > outfile
```

Example 2:
```bash
./pipex infile "grep a1" "wc -w" outfile
```
Should be the same as:
```bash
< infile grep a1 | wc -w > outfile
```