linux tar zip folder

Shell
tar cf ostechnix.tar ostechnix/
# Here, c flag refers create new archive and f refers the file name.tar -czvf name-of-archive.tar.gz /path/to/directory-or-file
Source

Also in Shell: