Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- @echo off
- set logfile="C:\Users\dmvlsorokin\bee\logfile.txt"
- chcp 65001 >>%logfile%
- set errlog="C:\...\errfile.txt"
- set conn_str="File=""C:\...\db"";"
- set exe_path="C:\Program Files\1cv8\8.3.5.1517\bin\1cv8.exe"
- set rep_path="S:\Хранилище\Develop"
- set rep_user=""
- set rep_pass=""
- set db_user="Федоров (администратор)"
- echo %date% %time%: killing everything 1>> %logfile%
- rem echo %date% %time%: killing everything
- rem for /F "tokens=2 delims=," %i in ('tasklist /V /FO CSV /NH /FI "IMAGENAME eq 1cv8.exe"') do @echo %i
- taskkill /F /IM 1cv8.exe 1>> %logfile% 2>> %errlog%
- taskkill /F /IM 1cv8c.exe 1>> %logfile% 2>> %errlog%
- copy %logfile% + %errlog% %logfile% > nul
- erase %errlog% >> %logfile%
- echo %date% %time%: batch configuration update start >> %logfile%
- %exe_path% CONFIG /IBConnectionString%conn_str% /UpdateDBCfg /N%db_user% /Out%logfile% -NoTruncate
- echo %date% %time%: updated >> %logfile%
- start "" %exe_path% CONFIG /IBConnectionString%conn_str% /N%db_user% /ConfigurationRepositoryF%rep_path% /ConfigurationRepositoryN%rep_user% /ConfigurationRepositoryP%rep_pass%
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement