-   Linux - General (
-   -   vim file.tex !latex file.tex & pdfdvi file.dvi & xpdf -remote sname -reload (

Mol_Bolom 07-09-2009 08:46 PM

vim file.tex !latex file.tex & pdfdvi file.dvi & xpdf -remote sname -reload
I'm not exactly sure where to post this, or even if there is a better title than that.

I had just recently learned about "xpdf -remote sessionname -reload", so now I can quickly view latex files directly after editing them from within vim. However, that is a lot of keystrokes, and I haven't even began learning about all the other commands for those programs.

I looked over the man pages of xdvi, which would save one extra step, but I didn't see anything about reloading a dvi file loaded in xdvi from a terminal.

Anyway, this is about the simplest that I can come up for editing latex files and viewing the data.
  1. Create a script file that will create an environment variable to the location of the file being edited, if necessary, and create another environment variable for naming the session. Run vim.
  1. Add aliases to my .profile or create a script file to run xpdf the first time using the environment variables and to reload xpdf.

I am just curious if there weren't some other methods/files/tricks that anyone would know that would make this a bit easier.

Also, what would happen if I recursively ran a script file? I don't think using xpdf -remote sessionname -reload will be a problem, but this is something I've been curious about.

All times are GMT -5. The time now is 05:17 PM.