id = "dar" name = "DAR" homepage = "https://dar.sourceforge.io" description = "Backup directory tree and files." executables = ["dar"] [dotfiles] # DAR's official documentation says it automatically reads $HOME/.darrc as a # user configuration file. A DCF can contain crypto options, so keep the whole # file secret rather than trying to infer which command-line tokens are keys. # https://dar.sourceforge.io/doc/Features.html paths = [] secret = ["~/.darrc"] side_effect = false [commands] format = 1 label = "Dar archive" description = "Create, extract, list or test a dar backup. Pick one action; each takes the archive basename (slice number and .dar are appended by dar). Encryption, differential backups, isolation, hooks and remote repositories are left out." quality = "ai-draft" parser = { end_of_options = "--", interleave = "permute", long_equals = true, short_attached = true, short_bundles = false } [[commands.source]] id = "man" kind = "manual" url = "https://manpages.debian.org/unstable/dar/dar.1.en.html" revision = "Debian unstable dar(1)" evidence = """ -c, --create -x, --extract -l, --list -t, --test -N, --noconf -n, --no-overwrite -e, --dry-run -v, --verbose -R, --fs-root -X, --exclude -I, --include -P, --prune -g, --go-into -z, --compression={ [algo] | level | algo:level | algo:level:block-size } --compression=9, --compression=lzo, --compression=gzip, --compression=bzip2, --compression=lzo:6, --compression=bzip2:2, --compression=gzip:1 --compression=xz:9 and so on. -s, --slice -s 10k -D, --empty-dir """ [[commands.field]] id = "create" label = "Create archive (basename)" type = "path" option = ["-c", "--create"] path = { kind = "any", role = "output", must_exist = false } effect = "overwrite" sources = ["man"] [[commands.field]] id = "extract" label = "Extract archive (basename)" type = "path" option = ["-x", "--extract"] path = { kind = "any", role = "input", must_exist = false } sources = ["man"] [[commands.field]] id = "list" label = "List archive (basename)" type = "path" option = ["-l", "--list"] path = { kind = "any", role = "input", must_exist = false } sources = ["man"] [[commands.field]] id = "test" label = "Test archive (basename)" type = "path" option = ["-t", "--test"] path = { kind = "any", role = "input", must_exist = false } sources = ["man"] [[commands.field]] id = "fs_root" label = "Root directory" description = "Directory tree to back up, or where to restore." type = "path" option = ["--fs-root", "-R"] path = { kind = "directory", role = "input", must_exist = true } sources = ["man"] [[commands.field]] id = "compression" label = "Compression" description = "algo, level, algo:level, e.g. gzip:6 or xz:9." type = "string" option = ["--compression"] value_style = "equals" suggestions = [{ value = "gzip:6", label = "gzip level 6" }, { value = "bzip2:2", label = "bzip2 level 2" }, { value = "xz:9", label = "xz level 9" }, { value = "lzo:6", label = "lzo level 6" }] sources = ["man"] [[commands.field]] id = "slice" label = "Slice size" description = "Bytes, or with k, M, G suffix (e.g. 10k)." type = "string" option = ["--slice", "-s"] sources = ["man"] [[commands.field]] id = "exclude" label = "Exclude masks" type = "string" option = ["--exclude", "-X"] multiple = true sources = ["man"] [[commands.field]] id = "include" label = "Include masks" type = "string" option = ["--include", "-I"] multiple = true sources = ["man"] [[commands.field]] id = "prune" label = "Prune paths" type = "path" option = ["--prune", "-P"] multiple = true path = { kind = "any", role = "input", must_exist = false } sources = ["man"] [[commands.field]] id = "empty_dir" label = "Keep empty directories for excluded ones" type = "boolean" option = ["--empty-dir", "-D"] sources = ["man"] [[commands.field]] id = "no_overwrite" label = "Do not overwrite" type = "boolean" option = ["--no-overwrite", "-n"] sources = ["man"] [[commands.field]] id = "dry_run" label = "Dry run" type = "boolean" option = ["--dry-run", "-e"] sources = ["man"] [[commands.field]] id = "noconf" label = "Ignore ~/.darrc and /etc/darrc" type = "boolean" option = ["--noconf", "-N"] sources = ["man"] [[commands.field]] id = "verbose" label = "Verbose" type = "boolean" option = ["--verbose", "-v"] sources = ["man"] [[commands.task]] id = "backup" label = "Create a backup" fields = ["create", "fs_root", "compression", "slice", "exclude", "include", "prune", "empty_dir", "verbose"] required = ["create", "fs_root"] [[commands.task]] id = "restore" label = "Extract a backup" fields = ["extract", "fs_root", "include", "exclude", "no_overwrite", "dry_run", "verbose"] required = ["extract"] [[commands.task]] id = "inspect" label = "List archive contents" fields = ["list"] required = ["list"] [[commands.group]] id = "basic" label = "Basic" fields = ["create", "extract", "list", "test", "fs_root", "compression", "slice"] [[commands.group]] id = "advanced" label = "Advanced" fields = ["exclude", "include", "prune", "empty_dir", "no_overwrite", "dry_run", "noconf", "verbose"]