It can be also done without Python. D'oh. Here is the batch file:
@ECHO OFF inkscape %* 2>&1>"%TEMP%.\console.txt" TYPE "%TEMP%.\console.txt" DEL "%TEMP%.\console.txt"
But it's sorta annoying that it needs a temporary file.
inkscape -e image.png drawing.svg 2>&1|more
For example works fine, but it adds that page feeding stuff. Using sort instead of more kind of works, but the output is of course sorted. Hum. I can't really believe that there isn't something which takes stdin and outputs it to stdout. Neither echo nor redirecting to con work. Did I overlook something obvious?
The best I could come up with is this batch:
@FOR /F "delims=" %%? IN ('inkscape %* 2^>^&1') DO @ECHO.%%?It works as intended, but eats empty lines.
Update: See inkscapec.exe - A Command Line Wrapper for Win32 for a better solution.
Comments
Post new comment