-
Notifications
You must be signed in to change notification settings - Fork 17
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
https://github.com/jackdewinter/pymarkdown/issues/1280
- Loading branch information
1 parent
2b26b0f
commit b4c9127
Showing
7 changed files
with
110 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,3 +9,4 @@ build/ | |
dist/ | ||
pymarkdownlnt.egg-info/ | ||
p0.prof | ||
ff/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
@echo off | ||
setlocal EnableDelayedExpansion | ||
|
||
rem Set needed environment variables. | ||
|
||
:uniqLoop | ||
set "XX_TEMPFILE=%tmp%\xx_~%RANDOM%.tmp" | ||
if exist "%XX_TEMPFILE%" goto :uniqLoop | ||
|
||
set disable_list="extensions.markdown-task-list-items.enabled=@True" | ||
set disable_list=%disable_list%;"extensions.markdown-strikethrough.enabled=@True" | ||
set disable_list=%disable_list%;"extensions.markdown-extended-autolinks.enabled=@True" | ||
set disable_list=%disable_list%;"extensions.markdown-disallow-raw-html.enabled=@True" | ||
set disable_list=%disable_list%;"extensions.front-matter.enabled=@True" | ||
|
||
set filesCount=0 & for %%f in (ff\*) do @(set /a filesCount+=1 > nul) | ||
|
||
set "bool_replace=$^!" | ||
for %%a in (%disable_list%) do ( | ||
set temp_path=%%a | ||
call set next_path=%%temp_path:@=!bool_replace!%% | ||
echo. | ||
echo Scanning with setting: !next_path! | ||
set /a count = 0 | ||
for %%i in (ff\*) do ( | ||
set file_to_scan=%%i | ||
set /a count += 1 | ||
FOR /F "delims=" %%j IN ('python -c "print((!count! %% 10))"') DO set mcount=%%j | ||
if "!mcount!"=="0" ( | ||
echo !count! out of %filesCount% | ||
) | ||
pipenv run python main.py --strict --set "!next_path!" --return-code-scheme minimal scan !file_to_scan! > %XX_TEMPFILE% | ||
if ERRORLEVEL 1 ( | ||
type %XX_TEMPFILE% | ||
echo pipenv run python main.py --strict --set "!next_path!" --return-code-scheme minimal scan !file_to_scan! | ||
echo BADD !file_to_scan! | ||
) | ||
) | ||
echo !count! out of %filesCount% | ||
) | ||
|
||
set xx= | ||
erase %XX_TEMPFILE% |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,5 @@ | ||
pipenv run python main.py %1 %2 %3 %4 %5 %6 %7 %8 %9 | ||
set RETURN_CODE=%ERRORLEVEL% | ||
echo !RETURN_CODE! | ||
echo %RETURN_CODE% | ||
exit /b %RETURN_CODE% |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters