
Maciej Kalisiak wrote:
I am using Inkscape 0.45 on Windows XP SP2. I am using the *.7z version (not the installer executable) that I unpacked to a regular directory. I try to export some *.svg Inkscape images to PDF on the command-line, using:
<path to my inkscape>\inkscape.exe foo.svg -A foo.pdf
From the FAQ I understand I won't see any console output on Windows
because Inkscape is built as a GUI app. That's fine, but no file is generated either: inkscape runs, quietly exits, *and there is no foo.pdf* in the current directory. Same thing if I use -e option to try to generate a PNG, or any other format I have tried. Needless to say, I tried and I can export the images manually from within Inkscape no problem. Am I missing something?
Even though you don't have a console executable on win32 you can still capture the output by doing:
inkscape.exe file.svg 2>output.txt
Now as for your problem exporting I think you'll find that it works if you use full paths. Inkscape seems to use the inkscpe install directory as the working directory and it searches there for files unless you provide the full path. Don't forget quotes if there are spaces in the path:
"c:\path to\inkscape.exe" -A "c:\another path to\destination.pdf" "c:\third path to\source.svg" 2>log.txt
I've got a ton of Inkscape pics in my thesis, and it's a serious pain to have to export them all manually... (Aside: one annoying bug/lacking feature in this regard: when you select *.PDF filetype in the Save/Save a copy dialog, or any other format, the extension in the filename entry field is not automatically changed; you have to go edit it manually... argh....)
I believe this is fixed in SVN trunk.
Aaron Spike