Update, maybe v1.0
This commit is contained in:
@@ -1,14 +1,8 @@
|
||||
chcp 65001 > NUL
|
||||
@REM ↑文字コードのおまじないらしい
|
||||
@echo off
|
||||
|
||||
@REM https://github.com/Zuntan03/EasyBertVits2 より引用・改変
|
||||
|
||||
|
||||
@REM 2. Style-Bert-VITS2.zip を解凍(名前がBert-VITS2-masterになる)
|
||||
@REM 3. Style-Bert-VITS2-master を Style-Bert-VITS2 にリネーム
|
||||
|
||||
|
||||
@echo off
|
||||
pushd %~dp0
|
||||
set PS_CMD=PowerShell -Version 5.1 -ExecutionPolicy Bypass
|
||||
|
||||
@@ -30,11 +24,13 @@ if %errorlevel% neq 0 ( pause & popd & exit /b %errorlevel% )
|
||||
%PS_CMD% Expand-Archive -Path Style-Bert-VITS2.zip -DestinationPath . -Force
|
||||
if %errorlevel% neq 0 ( pause & popd & exit /b %errorlevel% )
|
||||
|
||||
@REM 元のzipを削除しStyle-Bert-VITS2-master を Style-Bert-VITS2 にリネーム
|
||||
@REM 元のzipを削除
|
||||
del Style-Bert-VITS2.zip
|
||||
if %errorlevel% neq 0 ( pause & popd & exit /b %errorlevel% )
|
||||
|
||||
ren Style-Bert-VITS2-master Style-Bert-VITS2
|
||||
@REM Bert-VITS2-masterの中身をStyle-Bert-VITS2に上書き移動
|
||||
xcopy /QSY .\Style-Bert-VITS2-master .\Style-Bert-VITS2
|
||||
rmdir /s /q Style-Bert-VITS2-master
|
||||
|
||||
@REM Pythonと仮想環境のセットアップを呼び出す(仮想環境が有効化されて戻ってくる)
|
||||
call Style-Bert-VITS2\scripts\Setup-Python.bat ..\..\lib\python ..\venv
|
||||
|
||||
35
scripts/Update-Style-Bert-VITS2.bat
Normal file
35
scripts/Update-Style-Bert-VITS2.bat
Normal file
@@ -0,0 +1,35 @@
|
||||
chcp 65001 > NUL
|
||||
@echo off
|
||||
|
||||
pushd %~dp0
|
||||
set PS_CMD=PowerShell -Version 5.1 -ExecutionPolicy Bypass
|
||||
|
||||
set CURL_CMD=C:\Windows\System32\curl.exe
|
||||
if not exist %CURL_CMD% (
|
||||
echo [ERROR] %CURL_CMD% が見つかりません。
|
||||
pause & popd & exit /b 1
|
||||
)
|
||||
|
||||
@REM Style-Bert-VITS2.zip をGitHubのmasterの最新のものをダウンロード
|
||||
%CURL_CMD% -Lo Style-Bert-VITS2.zip^
|
||||
https://github.com/litagin02/Style-Bert-VITS2/archive/refs/heads/master.zip
|
||||
if %errorlevel% neq 0 ( pause & popd & exit /b %errorlevel% )
|
||||
|
||||
@REM Style-Bert-VITS2.zip を解凍(フォルダ名前がBert-VITS2-masterになる)
|
||||
%PS_CMD% Expand-Archive -Path Style-Bert-VITS2.zip -DestinationPath . -Force
|
||||
if %errorlevel% neq 0 ( pause & popd & exit /b %errorlevel% )
|
||||
|
||||
@REM 元のzipを削除
|
||||
del Style-Bert-VITS2.zip
|
||||
if %errorlevel% neq 0 ( pause & popd & exit /b %errorlevel% )
|
||||
|
||||
@REM Bert-VITS2-masterの中身をStyle-Bert-VITS2に上書き移動
|
||||
xcopy /QSY .\Style-Bert-VITS2-master .\Style-Bert-VITS2
|
||||
rmdir /s /q Style-Bert-VITS2-master
|
||||
if %errorlevel% neq 0 ( pause & popd & exit /b %errorlevel% )
|
||||
|
||||
echo Style-Bert-VITS2のアップデートが完了しました。
|
||||
|
||||
pause
|
||||
|
||||
popd
|
||||
Reference in New Issue
Block a user