Package: restorething
restorethingis a tool for restoring files from a syncthing
versioning archive. Supplyrestorethingthe path to the syncthing
versioning directory and a date, it will index the available files in
the versioning archive and restore files for you.restorethinghas multiple restore modes and the ability to filter
files and directories.Restore Modesrestorethingwill restore files using the following modesNearest file before/after a specific date/time (default behaviour)Nearest file before a specific date/timeNearest file after a specific date/timeAll instances of a specific file with no date/time restrictionrestorethinghas filtering optionsFilter files with specific stringFilter dir with specific stringFilter both dir and file with specific stringInstallationrestorethingfrom source$pythonsetup.pysdist$pipinstalldist\restorething-x.x.x.tar.gzrestorethingfrom PyPI$pipinstallrestorethingUsage$ python-mrestorething { date [-hr{0-24}|-b|-a|-pm{int} |-ai{path and filename} |-vd{dir} |-rd{dir} |-dd{dir} |-df{filename} |-nf|-nd|-ic|-ns| [-ff{string} |-fd{string} |-fb{path and filename} ] |-d|--version]}ArgumentTypeFormatDefaultDescriptiondateintegerYYYYMMDDNo default value. Field
must be supplied by userDate to restore
files, date will
be used to find
closest file
before or after
date-hrinteger-hr {0-24}12Hour to compare
file’s
modification time-bswitch-bdisabledLimit restore of
files to before
the supplied date
and hour-aswitch-adisabledLimit restore of
files to after
the supplied date
and hour-pminteger-pm
{0-2147483647
hrs}0Limit restore of
files to
plus/minus hours
each side of the
supplied date and
hour-aistring-ai {absolute
path of file}disabledRecovers all
versions of a
file ignoring any
date and times
specified-vdstring-vd {absolute
or relative
path of DIR}.stversionsSets the location
of the syncthing
versioning
folder, by
default script
looks in
directory script
is run from-rdstring-rd {absolute
or relative
path of DIR}restoreEnables the
ability to
restore to a
location other
than the default-ddstring-dd {absolute
or relative
path of DIR}/home/name/.restorethingEnables the
ability to use a
database file in
a different
location, default
behaviour is to
store database
file in users
home directory-dfstring-df
{filename}restorething.dbEnables the
ability to use a
database file
with a different
name-nfswitch-nfdisabledEnables indexing
archived files
every time script
is run, by
default script
will reuse
existing DB file
for 24 hours-ndswitch-nddisabledEnables restoring
files that have
been deleted or
changed due to
renaming, by
default deleted
or renamed files
are not included
in restore-icswitch-icdisabledEnables restoring
files that were
marked as
conflict files by
syncthing and
deleted by user,
by default
conflict files
are not restored-nsswitch-nsdisabledEnables no
simulation mode,
default behaviour
is to simulate
restore, no
simulation mode
will copy files
from syncthing
archive to hard
drive-ffstring-ff {string}disabledRecovers a single
version of any
files matching
the string
supplied-fdstring-fd {string}disabledRecovers a single
version of all
files in any DIR
matching the
string supplied-fbstring-fb {absolute
path of file}disabledRecovers a single
version of a file
matching the DIR
and Filename-dswitch-ddisabledEnables debug
output to console–versionswitch–versiondisabledDisplays versionDefault behaviourThe default behaviour of the script is to look for the closest file
older (before) than supplied date/time. If nothing is found, the
script looks for the closest file younger (after) than supplied
date/time. The default behaviour can be limited to plus/minus hours
by supplying-pm{hours}argument or changed to only looking
before or after supplied date/time by using the-bor-aflags, respectively.If no hour is supplied the default time value the script uses is
12pm. This can be changed by using the-hr{0-24}argumentThe script will always simulate a restore by default giving the user
an opportunity to review any detected warnings. By supplying the -ns
flag, the user can enable the no simulation mode and do an actual
restore, no simulation, no undo.The script will create a directory named restore in the directory the
script is being called from and restore all files recursively inside
of itIf no syncthing versioning directory is supplied, the default
behaviour is to look in the directory the script is being called
from.All config, log and database files are stored in user’s home
directory under the directory named .restorething.ExamplesRestore closest file before 6am 15th August 2016, if no file is found
restore closet file after 6am 15th August 2016. Due to not supplying
versioning directory, script will need to be called from directory
containing versioning directory$python-mrestorething20160815-hr6Restore closest file after 6am 15th August 2016, if no file is found, no
file will be restored. Versioning directory is supplied as a relative
path to where the script is being called from.$python-mrestorething20160815-hr6-a-vdsync/.stversionsRestore closest file before 6am 15th August 2016, if no file is found,
no file will be restored. Versioning directory is supplied as a relative
path to where the script is being called from.$python-mrestorething20160815-hr6-b-vdsync/.stversionsRestore closest file no more than 10 hours before 6am 15th August 2016,
if no file is foundrestorethingwill look for the closet file no
more than 10 hours after 6am 15th August 2016. Versioning directory is
supplied as a relative path to where the script is being called from.$python-mrestorething20160815-hr6-pm10-vdsync/.stversionsRestore all instances of a file located in directory/some/important/directory/, namedfile.txt. Current script
limitation is you have to supply a date, although it will be ignored.$python-mrestorething20160815-ai/some/important/directory/file.txt