Skip to content

andreip/huffman-tar

master
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

About

It's a compression tool like tar czf file.zip file1 file2 ..., but it does compression by using the huffman coding trees.

It does not work with directories, only with simple files for simplicity.

How it works

Follow the below steps and see it working

# compile huffman project
$ make

# compress similar to tar syntax
$ ./hufftar compress out.huff file1 file2 ...

$ ls -l out.huff

# decompress to folder 1/
$ mkdir 1/
$ ./hufftar extract out.huff 1/

# list the .huff compressed files
$ ./hufftar list out.huff

Get convinced it actually compresses

$ ./hufftar compress out.huff file1 file2 ...
$ tar cf out.tar file1 file2 ...
# Compare their sizes, out.tar only puts the files file1,file2 together without compression
# While out.huff should be significantly lower.
$ ls -l out.huff out.tar

About

Compression Tool using Huffman Trees

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages