File size: 1,396 Bytes
9d6c005 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 | @echo off
setlocal
cd /d "%~dp0"
echo AUREOLE-R - Public Hugging Face research release
echo Destination: PureOne/AUREOLE-R-v3 unless overridden with --repo ACCOUNT/NAME
echo Your token will be requested privately. Do not put it in this file.
echo.
if exist ".venv-publish\Scripts\python.exe" goto dependencies
py -3 -c "import sys; sys.exit(sys.version_info[:2] < (3, 10))" >nul 2>&1
if errorlevel 1 goto try_python
py -3 -m venv ".venv-publish"
if errorlevel 1 goto failed
goto dependencies
:try_python
python -c "import sys; sys.exit(sys.version_info[:2] < (3, 10))" >nul 2>&1
if errorlevel 1 goto no_python
python -m venv ".venv-publish"
if errorlevel 1 goto failed
:dependencies
".venv-publish\Scripts\python.exe" scripts\publish_hf.py
if errorlevel 1 goto failed
".venv-publish\Scripts\python.exe" -m pip install --disable-pip-version-check -r requirements-publish.txt
if errorlevel 1 goto failed
".venv-publish\Scripts\python.exe" scripts\publish_hf.py --publish %*
if errorlevel 1 goto failed
echo.
echo Complete. The verified public URL and commit are in publication_receipt.json.
pause
exit /b 0
:no_python
echo Python 3.10 or later is required. Install Python from python.org, then run this file again.
pause
exit /b 1
:failed
echo.
echo Publication did not finish with verification. Read the message above and run this file again.
pause
exit /b 1
|