sqlar

vb sqlar VERSION OUTPUTFILE [OPTIONS]

Description

Generate an SQLAR archive for a check-in. If the --name option is used, its argument becomes the name of the top-level directory in the resulting SQLAR archive. If --name is omitted, the top-level directory name is derived from the project name, the check-in date and time, and the artifact ID of the check-in.

The GLOBLIST argument to --exclude and --include can be a comma-separated list of glob patterns, where each glob pattern may optionally be enclosed in ... or ... so that it may contain commas. If a file matches both --include and --exclude then it is excluded.

If OUTPUTFILE is an empty string or /dev/null then no SQLAR archive is actually generated. This feature can be used in combination with the --list option to get a list of the filenames that would be in the SQLAR archive had it actually been generated.

Options

-X, --exclude GLOBLIST

Comma-separated list of GLOBs of files to exclude

--include GLOBLIST

Comma-separated list of GLOBs of files to include

-l, --list

Show archive content on stdout

--name DIRECTORYNAME

The name of the top-level directory in the archive

-R REPOSITORY

Specify a VisionByte repository

Examples

  • Init and open a repository

$ vb init sqlar_repo.vbyte
project-id: 7be08754a679a388b352ad845e36c17414a49b59
server-id:  8c8122307f69b2432d7aa8337a7c410b3889a33d
admin-user: ubuntu (initial remote-access password is "MEP398hiom")
$ vb open -f sqlar_repo.vbyte
project-name: <unnamed>
repository:   /tmp/sphinx_tests/779fa9b9/sqlar_repo/sqlar_repo.vbyte
local-root:   /tmp/sphinx_tests/779fa9b9/sqlar_repo/
config-db:    /tmp/sphinx_tests/779fa9b9/.visionbyte
project-code: 7be08754a679a388b352ad845e36c17414a49b59
checkout:     0ace561eea94e1c6e1ec096cb8c4e907da878846 2026-04-07 06:51:39 UTC
tags:         trunk
comment:      initial empty check-in (user: ubuntu)
check-ins:    1
  • Add files and commit them, then create a sqlar archive of the current version

$ vb sys echo "a" > a.txt
$ vb sys echo "b" > b.txt
$ vb sys mkdir subdir
$ vb sys echo "c" > subdir/c.txt
$ vb add a.txt b.txt subdir
ADDED  a.txt
ADDED  b.txt
ADDED  subdir/c.txt
$ vb ci -m "base"
Committed version: 4f9d7092a1b642e527e080aa0e0cb9a1ecbf1dd1545714c53ff7793c3e504612
$ vb sqlar current current.sqlar
$ vb sys ls -l current.sqlar
-rw-r--r-- 1536 2026-04-07 06:51:39 current.sqlar
  • Set the the top-level directory in the archive to “current” and list the SQLAR archive contents

$ vb sqlar current /dev/null --name current -l
current/a.txt
current/b.txt
current/subdir/c.txt