Saturday, 7 June 2025

robocopy

 # Copy from g: to c: but exclude files *.iso *.log and directories g:\dir1 etc.
robocopy G: C:\backup /MIR /Z /LOG:C:\todaysdate-backup.log /XF *.iso *.log *.au /XD G:\dir1 G:\dir3
# Another way to exclude
Let us take this example list of exclusions stored in the following file

exclude.rcj
/XF
    *.pyc
    *.pyo
    *.pyd

/XD
    __pycache__
    .pytest_cache

Note how we are able to have multiple switches inside the file and separate the names with new lines for better readability !

Our batch script can then be something along the lines of:

backup.bat

SET _backupDir=backup_path\
SET _excl="%_backupDir%exclude.rcj"

robocopy src_path dest_path /JOB:%_excl%

TermRecord

TermRecord is a simple terminal session recorder with easy-to-share self-contained HTML output! TermRecord -o /tmp/session.html