-
Notifications
You must be signed in to change notification settings - Fork 480
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #337 from 4ybaka/issue-323-tar-archive-finalization
Added ability to leave tar archive open after stream is closed
- Loading branch information
Showing
5 changed files
with
54 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
using SharpCompress.Archives; | ||
using SharpCompress.Common; | ||
|
||
namespace SharpCompress.Writers.Tar | ||
{ | ||
public class TarWriterOptions : WriterOptions | ||
{ | ||
/// <summary> | ||
/// Indicates if archive should be finalized (by 2 empty blocks) on close. | ||
/// </summary> | ||
public bool FinalizeArchiveOnClose { get; } | ||
|
||
public TarWriterOptions(CompressionType compressionType, bool finalizeArchiveOnClose) | ||
: base(compressionType) | ||
{ | ||
FinalizeArchiveOnClose = finalizeArchiveOnClose; | ||
} | ||
|
||
internal TarWriterOptions(WriterOptions options) : this(options.CompressionType, true) | ||
{ | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters