Closed PaulicStudios closed 5 months ago
should be related to /bin/echo >/dev/null 1 | /bin/echo 2
should be splitted up into the right tokens not into one
/workspaces/42-minishell ❯ /bin/echo >/dev/null 1 | /bin/echo 2 Tokens: Type: 0, Value: /bin/echo, BE-Value: (null) Type: 15, Value: , BE-Value: (null) Type: 5, Value: >, BE-Value: (null) Type: 0, Value: /dev/null, BE-Value: (null) Type: 15, Value: , BE-Value: (null) Type: 0, Value: 1, BE-Value: (null) Type: 15, Value: , BE-Value: (null) Type: 8, Value: |, BE-Value: (null) Type: 15, Value: , BE-Value: (null) Type: 0, Value: /bin/echo, BE-Value: (null) Type: 15, Value: , BE-Value: (null) Type: 0, Value: 2, BE-Value: (null) Tokens: Type: 0, Value: /bin/echo, BE-Value: (null) Type: 15, Value: , BE-Value: (null) Type: 5, Value: >, BE-Value: (null) Type: 0, Value: /dev/null, BE-Value: (null) Type: 15, Value: , BE-Value: (null) Type: 0, Value: 1, BE-Value: (null) Type: 15, Value: , BE-Value: (null) Type: 8, Value: |, BE-Value: (null) Type: 15, Value: , BE-Value: (null) Type: 0, Value: /bin/echo, BE-Value: (null) Type: 15, Value: , BE-Value: (null) Type: 0, Value: 2, BE-Value: (null) Tokens: Type: 0, Value: /bin/echo, BE-Value: (null) Type: 15, Value: , BE-Value: (null) Type: 5, Value: >, BE-Value: (null) Type: 0, Value: /dev/null, BE-Value: (null) Type: 15, Value: , BE-Value: (null) Type: 0, Value: 1, BE-Value: (null) Type: 15, Value: , BE-Value: (null) Type: 8, Value: |, BE-Value: (null) Type: 15, Value: , BE-Value: (null) Type: 0, Value: /bin/echo, BE-Value: (null) Type: 15, Value: , BE-Value: (null) Type: 0, Value: 2, BE-Value: (null) Tokens: Type: 0, Value: /bin/echo, BE-Value: (null) Type: 15, Value: , BE-Value: (null) Type: 0, Value: >/dev/null, BE-Value: (null) Type: 15, Value: , BE-Value: (null) Type: 0, Value: 1, BE-Value: (null) Type: 8, Value: |, BE-Value: (null) Type: 0, Value: /bin/echo, BE-Value: (null) Type: 0, Value: 2, BE-Value: (null) Type: 0, Value: /bin/echo Prio: 1 Type: 0, Value: 2 Prio: 1 Type: 8, Value: | Prio: 3 Type: 0, Value: /bin/echo Prio: 1 Type: 15, Value: Prio: 1 Type: 0, Value: >/dev/null Prio: 1 Type: 15, Value: Prio: 1 Type: 0, Value: 1 Prio: 1 ----- Type: 16, Value: /bin/echo Prio: -1 Type: 13, Value: /bin/echo2 Prio: -1 Type: 8, Value: | Prio: 3 Type: 13, Value: /bin/echo Prio: -1 Type: 15, Value: Prio: -1 Type: 14, Value: >/dev/null Prio: -1 Type: 15, Value: Prio: -1 Type: 14, Value: 1 Prio: -1 executing /bin/echo: in -1 out 4 executing /bin/echo2: in 3 out -1 minishell: /bin/echo2: No such file or directory waiting for /bin/echo2... waiting for /bin/echo...
also probably to
ls >"./outfiles/outfile""1""2""3""4""5"
should interpret > as an out file
>tmp_out | echo 1
should execute like> tmp_out | echo 1