my pdflatex setup
Jun. 12th, 2010 12:19 pm![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Since I can't seem to purge my machine from tex things (even "apt-get purge" gets into trouble because of missing files), I'm using a script to run pdflatex remotely:
It's kinda ridiculous... for one, I need to type my password 3 times every time. Is there a way to be automatically authenticated, or have the password sent automatically?
scp temp.tex gusl@stat.ubc.ca:thesis ssh gusl@stat.ubc.ca 'cd thesis; pdflatex temp.tex' scp gusl@stat.ubc.ca:thesis/temp.pdf .
It's kinda ridiculous... for one, I need to type my password 3 times every time. Is there a way to be automatically authenticated, or have the password sent automatically?
(no subject)
Date: 2010-06-12 07:56 pm (UTC)The "correct" (secure, but a bit of a faff) way of doing it is described at http://www.debian-administration.org/articles/152
There's also an 'sshpass' utility that will let you supply ssh (and I think also scp) with the password from a script:
$sudo apt-get install sshpass
$sshpass -p yourpassword ssh gusl@stat.ubc.ca 'cd thesis; pdflatex temp.tex'
This comes with dire security warnings -- which IMO aren't all that bad if you're the only person using your computer
Ubuntu's own password manager doesn't seem to integrate well with command-line scp, I'm afraid.
(no subject)
Date: 2010-06-12 09:49 pm (UTC)(no subject)
Date: 2010-06-13 12:56 am (UTC)(no subject)
Date: 2010-06-14 03:14 pm (UTC)(no subject)
Date: 2010-06-13 02:59 am (UTC)ssh gusl@stat.ubc.ca 'cd thesis && cat >temp.tex && pdflatex temp.tex && cat temp.pdf && rm -f temp.{tex,pdf}' <temp.tex >temp.pdf
(Sorry about the edits, it was eating some chars.
(no subject)
Date: 2010-06-13 03:17 am (UTC)I have to say, I find the syntax kinda funky.
Let's see if I understand:
*
<temp.tex
copies the local temp.tex to the input buffer*
cat >temp.tex
writes the input buffer to the remote temp.tex*
cat temp.pdf
writes to the output buffer*
>temp.pdf
uses the output buffer to create a local temp.pdfDid I get this right?
(And yeah it's really annoying to have to write "& gt;", etc.)
(no subject)
Date: 2010-06-13 07:20 am (UTC)(no subject)
Date: 2010-06-15 12:19 am (UTC)(no subject)
Date: 2010-06-13 05:16 am (UTC)sometimes, strange apt problems can be solved by rm'ing /var/cache/apt/pkgcache.bin and /var/cache/apt/srcpkgcache.bin, followed by doing an apt-get update.
The rest of the thead has some good suggestions, including asking the debian packagers for support.
(no subject)
Date: 2010-06-13 08:08 am (UTC)apt-get still has the same problem, whether it's purging texlive or installing sshpass:
Setting up tex-common (2.06) ...
Error: The new file /usr/share/tex-common/05TeXMF.cnf does not exist!
dpkg: error processing tex-common (--configure):
subprocess installed post-installation script returned error exit status 1
I don't see why it tries to set up tex-common when what I'm asking it to do is totally unrelated.
(no subject)
Date: 2010-06-13 02:00 pm (UTC)I suggest contacting someone who knows how to tidy up apt-get.