This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| @echo off | |
| setlocal EnableExtensions EnableDelayedExpansion | |
| REM ===== Configuration ===== | |
| set BACKUP_DEST=. | |
| for /f %%I in ('powershell -NoProfile -Command "Get-Date -Format yyyy-MM-dd_HH_mm_ss"') do set TIMESTAMP=%%I | |
| set BACKUP_FILE=%BACKUP_DEST%\%TIMESTAMP% zydesktop.7z | |
| set LOG_FILE=%BACKUP_DEST%\%TIMESTAMP%_backup.log | |
| set FAIL_LOG=%BACKUP_DEST%\%TIMESTAMP%_backup_failed.log |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Uses jxr_to_png.exe from https://github.com/ledoge/jxr_to_png | |
| Add-Type -AssemblyName PresentationCore | |
| Add-Type -AssemblyName WindowsBase | |
| Add-Type -AssemblyName System.Windows.Forms | |
| function Copy-FileToClipboard { | |
| param([string]$filePath) | |
| $files = New-Object System.Collections.Specialized.StringCollection |