scripts/pvlbackup-rsync-snapshot
changeset 30 29b60df79122
parent 22 a2bc5cc9de4d
child 31 e946c741c500
equal deleted inserted replaced
29:5abd153d78eb 30:29b60df79122
     8     Updates symlink <dst>/current -> <dst>/snapshots/...
     8     Updates symlink <dst>/current -> <dst>/snapshots/...
     9 
     9 
    10     Then archives <dst>/current to <dst>/<period>/<date> using --link-dest.
    10     Then archives <dst>/current to <dst>/<period>/<date> using --link-dest.
    11 """
    11 """
    12 
    12 
       
    13 from pvl.backup import __version__
    13 from pvl.backup import rsync
    14 from pvl.backup import rsync
    14 
    15 
    15 import optparse, ConfigParser
    16 import optparse, ConfigParser
    16 import os, os.path, stat
    17 import os, os.path, stat
    17 import shutil
    18 import shutil
    29     """
    30     """
    30 
    31 
    31     parser = optparse.OptionParser(
    32     parser = optparse.OptionParser(
    32             prog        = argv[0],
    33             prog        = argv[0],
    33             usage       = '%prog: [options] [ --config <path> | --target <path> [ --source <src> ] [ --interval <name> ] ]',
    34             usage       = '%prog: [options] [ --config <path> | --target <path> [ --source <src> ] [ --interval <name> ] ]',
       
    35             version     = __version__,
    34 
    36 
    35             # module docstring
    37             # module docstring
    36             # XXX: breaks multi-line descriptions..
    38             # XXX: breaks multi-line descriptions..
    37             description = __doc__,
    39             description = __doc__,
    38     )
    40     )