Commit Graph

4 Commits

Author SHA1 Message Date
7339aeeae5
chore: Add platform-specific example targets
Someone might want to build only the examples that work on non-POSIX, or the ones that work on POSIX.
2023-02-05 14:33:59 +01:00
482ac6d949
feat: Add write support
This uses a new struct (struct minitar_w).
This struct is initialized using the minitar_open_w function, and deleted using minitar_close_w.

The functions to write to an archive are minitar_write_file_entry() and minitar_write_special_entry().
The difference is that regular files have content, while the rest (special entries) do not.

This commit also adds a new example program (pack), which can create tar archives from files (no directory support though).

Archives created using pack and minitar can be read and extracted using GNU tar!!

Documentation is coming in another commit.
2023-02-04 19:02:08 +01:00
56250a226f
chore: Add a CMake target to build all examples 2023-01-19 22:44:01 +01:00
240a4f2f1a
chore: Add examples to CMake as opt-in targets 2023-01-19 22:30:23 +01:00