Skip to content

Commit 0d13333

Browse files
authored
Merge pull request winpython#963 from stonebig/master
DOS subtelty patch
2 parents d4da6fb + 5355d67 commit 0d13333

File tree

1 file changed

+9
-16
lines changed

1 file changed

+9
-16
lines changed

run_complement_newbuild.bat

Lines changed: 9 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -26,9 +26,9 @@ cd /d %new_winpydir%
2626
call scripts\env.bat
2727
@echo off
2828

29-
rem * ==========================
30-
rem * When Python has no mingwpy
31-
rem * ==========================
29+
rem * ==========================
30+
echo * When Python has no mingwpy
31+
rem * ==========================
3232
if not exist "%WINPYDIR%\Lib\site-packages\mingwpy" set pydistutils_cfg=%WINPYDIR%\..\settings\pydistutils.cfg
3333
if not exist "%WINPYDIR%\Lib\site-packages\mingwpy" echo [config]>%pydistutils_cfg%
3434

@@ -57,28 +57,21 @@ rem * =================
5757
if exist "%WINPYDIR%\Lib\site-packages\seaborn" "%WINPYDIR%\python.exe" -c "import seaborn as sns;sns.set();sns.load_dataset('iris')"
5858

5959

60-
rem * =================
61-
echo opengl PyQt5 patch 2018-01-06
62-
rem * ==================
63-
set qt56p=%WINPYDIR%\Lib\site-packages\PyQt5\Qt\bin
64-
set qt56dest=%WINPYDIR%\Lib\site-packages\PyQt5\Qt\bin\opengl32sw.dll
65-
if exist "%qt56p%" if not exist "%qt56dest%" (
66-
if "%WINPYARCH%"=="WIN32" copy "C:\WinPython\bd35\patch_qt570\opengl32sw-32\opengl32sw.dll" "%WINPYDIR%\Lib\site-packages\PyQt5\Qt\bin\opengl32sw.dll"
67-
)
68-
if not "%WINPYARCH%"=="WIN32" copy "C:\WinPython\bd35\patch_qt570\opengl32sw-64\opengl32sw.dll" "%WINPYDIR%\Lib\site-packages\PyQt5\Qt\bin\opengl32sw.dll"
69-
)
70-
7160
rem ** Active patchs**
7261
rem * ===========================
73-
rem 2021-04-17 patch jupyter_lsp-1.1.4
62+
echo 2021-04-17 patch jupyter_lsp-1.1.4
7463
rem see https://github.com/krassowski/jupyterlab-lsp/pull/580/files
7564
rem * ===========================
65+
66+
rem in DOS, the variable must be set befor the parenthesis block....
67+
set this_source='%WINPYDIR%\Lib\site-packages\jupyter_lsp\virtual_documents_shadow.py'
7668
if exist "%WINPYDIR%\Lib\site-packages\jupyter_lsp-1.1.4.dist-info" (
77-
set this_source='%WINPYDIR%\Lib\site-packages\jupyter_lsp\virtual_documents_shadow.py'
69+
echo "**%this_source%**"
7870
%WINPYDIR%\python.exe -c "from winpython.utils import patch_sourcefile;patch_sourcefile(r%this_source%, 'read_text()', 'read_text(encoding='+chr(39)+'utf-8'+chr(39)+')' )"
7971
%WINPYDIR%\python.exe -c "from winpython.utils import patch_sourcefile;patch_sourcefile(r%this_source%, 'join(self.lines))', 'join(self.lines), encoding='+chr(39)+'utf-8'+chr(39)+')' )"
8072
)
8173

74+
8275
rem ** Example of live file replacement (not active)**
8376
rem * ===========================
8477
rem 2020-05-15 patch jedi-0.17.0

0 commit comments

Comments
 (0)