zstd_compress_file: Zstd file compression

View source: R/RcppExports.R

zstd_compress_fileR Documentation

Zstd file compression

Description

A utility function to compresses a file with zstd.

Usage

zstd_compress_file(input_file, output_file, compress_level = qopt("compress_level"))

Arguments

input_file

Path to the file to compress.

output_file

Path for the compressed file.

compress_level

The compression level used.

Value

No value is returned. The file is written to disk.

Examples

infile <- tempfile()
writeBin(as.raw(1:5), infile)
outfile <- tempfile()
zstd_compress_file(infile, outfile, compress_level = 1)
stopifnot(file.exists(outfile))

qs2 documentation built on Nov. 21, 2025, 9:06 a.m.