Started working on the main library (nearly complete)

This commit is contained in:
Caleb Gardner
2023-12-24 08:05:56 -06:00
parent b2a3920c1f
commit 5de59627df
10 changed files with 550 additions and 16 deletions
+21
View File
@@ -0,0 +1,21 @@
package squashfs
import (
"io"
"io/fs"
)
type ExtractionOptions struct {
LogOutput io.Writer //Where error log should write.
DereferenceSymlink bool //Replace symlinks with the target file.
UnbreakSymlink bool //Try to make sure symlinks remain unbroken when extracted, without changing the symlink.
Verbose bool //Prints extra info to log on an error.
IgnorePerm bool //Ignore file's permissions and instead use Perm.
Perm fs.FileMode //Permission to use when IgnorePerm. Defaults to 0777.
}
func DefaultOptions() *ExtractionOptions {
return &ExtractionOptions{
Perm: 0777,
}
}