func (zs *Zstd) CheckExt(filename string) error {
	if filepath.Ext(filename) != ".zst" {
		return fmt.Errorf("filename must have a .zst extension")
	}
	return nil
}
CheckExt ensures the file extension matches the format.
package archiver
import (
	"fmt"
	"io"
	"path/filepath"
	"github.com/klauspost/compress/zstd"
)
type Zstd struct {
}
func (zs *Zstd) Compress(in io.Reader, out io.Writer) error {
	w, err := zstd.NewWriter(out)
	if err != nil {
		return err
	}
	defer w.Close()
	_, err = io.Copy(w, in)
	return err
}
func (zs *Zstd) Decompress(in io.Reader, out io.Writer) error {
	r, err := zstd.NewReader(in)
	if err != nil {
		return err
	}
	defer r.Close()
	_, err = io.Copy(out, r)
	return err
}