Closed mk-uc closed 4 years ago
+1
It is generating these files in an /appdata/local/temp folder, can we get some control over that from in this plugin? Where can we pass options and switches to the exe? Thanks
+1
I was just looking up if this was possible. It seems it wouldn't be hard to implement but I haven't looked at the code. If I get some time I might try to generate a pull request.
+1 It should be very useful, but it seems the "$file referring to current file" sublime text trick cannot be used in the pandoc arguments... Don't know how to do next.
Why can't it be used in the arguments? Yes it can't be added in the settings file. But if you have a setting in the settings file that states output in current folder. I don't see why in the plug in you can't get the current directory and file and append to the cmd argument list and check the argument list to make sure no output file is already specified. It already must append a temporary file if no output is detected so this would just need to be modified. I haven't looked at the code but this is what it seems like.
@excetara2 Sorry, I am new in tweaking ST settings... I just know $file
can be used in cmd
arguments. And if you use it here in pandoc-arguments
it shall be just interpreted as pure string instead of the file path. Hope you can make a PR and I will learn from it. Thanks!
Okay I've implemented this but didn't fork it but maybe next weekend as I have a busy week. It was all of two lines. I put two settings: one that can be implemented locally within each function called save-current-folder
and then a global setting always-use-current-folder
. Even though global, This function is only true when new-buffer
or output-path
are not explicitly set. I initially had only a local setting but thought some people may prefer never to save to a temporary file.
I need to modify this further actually. I must have only edited the section pertaining to output to pdf because that works flawless. Output to any other format doesn't. I have only been outputting to pdf because usually use live preview for viewing html.
Sorry for bothering... Improvement mentioned/done by @jhultgre is't already part of this package, right? How could I get this update using packagecontrol.io? Because this would be my preferred way.
Thanks in advance!
Fixed. See #64.
Is there a way to have this automatically save the generated file in same folder as the source file. And also to create it with the same name as the source file? This would make the process much smoother.