Skip to content

Latest commit

 

History

History
61 lines (53 loc) · 728 Bytes

README.md

File metadata and controls

61 lines (53 loc) · 728 Bytes

mysh-rs

My little shell implementation written in Rust

usage:

$ cargo run

Supported Features

Basic command execution

$ echo hoge
hoge

Pipes

$ echo hogehoge | sed s/hoge/fuga/ | rev
egohaguf

Redirections

$ ls > test.txt
$ echo hello >> test.txt
$ cat test.txt
Cargo.lock
Cargo.toml
README.md
src
test.txt
hello

Stdin from a file

$ tr . _ < Cargo.lock
# This file is automatically @generated by Cargo_
# It is not intended for manual editing_
[[package]]
name = "mysh2"
version = "0_1_0"

Here document

$ grep hello << EOF
hello
bye
hello world!
EOF
hello
hello world!

Here strings

$ sed s/$/world/ <<< hello
helloworld