Backup of the current project with today's date as a 7z archive
Asked 1 year 9 months 4 days 18 hours 57 minutes ago, Viewed 1618 times
7-Zip is free open source, cross-platform, powerful,
and full-featured file archiver with high compression ratio,
for Windows. It has a powerful command-line version that has been ported to Linux/POSIX systems.
With 7z you can backup your current project with today's date.
We set the date in the format: 2023.02.20_14.35
set mydate=%date:~6,4%.%date:~3,2%.%date:~0,2%_%TIME:~0,2%.%TIME:~3,2%
"C:\Program Files\7-Zip\7z.exe" a -r "D:\BACKUP\NetCode\%mydate%_Backup.7z" "C:\PROJECT\NetCode"
Output:Creating archive: D:\BACKUP\NetCode\2023.02.20_14.35_Backup.7z
Archive size: 396784765 bytes (379 MiB)
Everything is Ok
Like
1