stardog vcs revert Manual Page

NAME


stardog vcs revert —Reverts a database to a previous version. This command does not perform any conflict resolution and simply applies the corresponding diff in the reverse. All the additions specified in the given range will be removed and all the removals in the given range will be added. You can use the diff command with the same range to see the exact changes in the given range.

SYNOPSIS


stardog [ --krb5 ] [ --krb5-disable-rdns ]vcs revert {-m | --message} <message> [ {-p | --passwd} <password> ] [ {-P | --ask-password} ] [ --single ] [ {-u | --username} <username> ] [ {-v | --verbose} ] [--] <database> <[[startVersion]> <endVersion]>...

OPTIONS


--krb5
Use the Kerberos environment.
--krb5-disable-rdns
Disable reverse DNS lookup for Kerberos clients.
-m <message>, --message <message>
The commit message that will be associated with the new version.
-p <password>, --passwd <password>
Password.
-P, --ask-password
Prompt for password.
--single
Reverts a single version.
-u <username>, --username <username>
User name.
-v, --verbose
Verbose flag that causes more detailed information to be printed
--
This option can be used to separate command-line options from the list of argument, (useful when arguments might be mistaken for command-line options
<database> <[[startVersion]> <endVersion]>
The name of the database or the full connection string of the database to connect to. If only the name is provided, the default server URL will be pre-pended to the name of the database in order to construct the connection string. Connection parameters such as ';reasoning=true' can be included in the provided database name. Connection parameters specified like this can be overridden by specific options on the command. The default server URL will be read from the JVM argument 'stardog.default.cli.server'. If the JVM argument is not set, the default value 'http://localhost:5820' is used. If the server URL has no explicit port value, the default port value '5820' is used. To use a secure connection, you should specify the full connection string and postfix 's' to the protocol, e.g. https. Subsequent arguments specify the version range to revert. If endVersion is not given the HEAD version will be used. If --single is used then startVersion should be omitted and the version right before endVersion will be used. If both versions are omitted then --single is assumed. Versions can be identified with their full IRI, local name, or a tag (if one exists).

EXAMPLES


Reverts the last commit and restores the database to the previous version

    $ stardog vcs revert myDb

Reverts all the changes committed after a specific version effectively restoring to the state at the given version

    $ stardog vcs revert myDb de44369d-cc7b-4244-a3fb-3f6e271420b0 

Reverts all the changes committed after a specific version and everything else until (and including) the second version

    $ stardog vcs revert myDb de44369d-cc7b-4244-a3fb-3f6e271420b0 bd5b2cc8-c625-46ca-a5ce-934327d27e3c

Reverts the changes committed in one specific version.

    $ stardog vcs revert --single myDb de44369d-cc7b-4244-a3fb-3f6e271420b0

Revert all the changes committed after a tag.

    $ stardog vcs revert myDb myTag