REPOSYNC(1)

NAME
reposync - update OpenBSD source repository

SYNOPSIS
reposync [-46fq] [-p | -l username] [-s sets] [-w warntime] rsync://upstream/path [destination]

DESCRIPTION
reposync is a utility to update the OpenBSD source repository.

It connects to an rsync server, by default using ssh(1) port forwarding to allow verification of the upstream server. If only a short time has elapsed since the previous update, the CVSROOT directory on the upstream server is checked for changes (typically in the ChangeLog file) and the update is skipped if none are detected.

If destination is omitted, /cvs will be used.

A list of upstream servers holding the OpenBSD repository is available at https://www.openbsd.org/anoncvs.html.

/var/db/reposync and the destination directory must exist and be writable by the user running reposync.

The options are as follows.

-4  Connect using IPv4.

-6  Connect using IPv6.

-f  Force updating, even if CVSROOT has not been updated.

-l username
    ssh(1) port-forwarding is used with the specified username. By default, this is enabled with the username "anoncvs".

-p  Disable ssh(1) port-forwarding and use plaintext. This option is not recommended and may be removed in the future.

-q  Be quiet. By default, a list of files updated is output. Suggested use from cron(8) is to use the default reposync option but use the crontab(5) -n option to suppress the email unless a problem occurs, giving the most information in error conditions.

-s sets
    Specify a comma-separated list of file sets. By default, all standard sets are fetched: "www,xenocara,ports,src".

-w warntime
    If the sync takes longer than warntime seconds, display a warning and exit with an error code.

FILES
/var/db/reposync/reposync.hash
    stores a hash of the CVSROOT directory listing to detect if the repository has not changed
/var/db/reposync/known_hosts
/usr/local/share/reposync/ssh_known_hosts
    both passed to ssh(1) UserKnownHostsFile

The reposync package provides default hostkeys of official OpenBSD mirrors known to support rsync over ssh-forwarding in /usr/local/share/reposync/ssh_known_hosts. If using an unofficial mirror, add the host key to /var/db/reposync/known_hosts.

EXAMPLES
$ doas -u cvs reposync rsync://mirror.example.org/cvs

Connect via ssh(1) to anoncvs@mirror.example.org and use the port-forward functionality to connect to rsync using an encrypted, authenticated channel and update the default local directory /cvs.

$ doas -u cvs reposync -s src,xenocara rsync://mirror.example.org/cvs

As above, but only fetch "src" and "xenocara" sets.

$ reposync -q rsync://mirror.example.org/cvs ~/cvs

Connect via ssh(1) to anoncvs@mirror.example.org and update the local directory ~/cvs. Use quiet output.

SEE ALSO
cvs(1), rsync(1), ssh(1)