`latexmk` with cleanup and `-pvc`
up vote
0
down vote
favorite
I am unable to put the -pvc
(preview continuously) and -c
(clean up) options together for latexmk
.
latexmk -pdf -pvc -c file.tex
My observation: After giving -c
option, the file gets compiled, (regeneratable) files are deleted and I am back to the command prompt.
Is it possible to achieve this?
-- Mike
latexmk
bumped to the homepage by Community♦ 6 hours ago
This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.
add a comment |
up vote
0
down vote
favorite
I am unable to put the -pvc
(preview continuously) and -c
(clean up) options together for latexmk
.
latexmk -pdf -pvc -c file.tex
My observation: After giving -c
option, the file gets compiled, (regeneratable) files are deleted and I am back to the command prompt.
Is it possible to achieve this?
-- Mike
latexmk
bumped to the homepage by Community♦ 6 hours ago
This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.
I'm not quite understanding.-pvc
implies continuous compilation, which needs the auxiliary files, which means they can't be deleted. Or are you wanting the auxiliary files to be regenerated whenever you make a change? Why not just leave them around?
– Teepeemm
Sep 29 at 18:42
@Teepeemm This is precisely I want! I would like to regenerate all auxiliary files every time src file.tex is updated. and get deleted upon successful compilation. I need this as I have some restrictions on bandwidth and filesystem in terms of number of files. (Weird, huh?)
– Mike V.D.C.
Sep 30 at 6:36
add a comment |
up vote
0
down vote
favorite
up vote
0
down vote
favorite
I am unable to put the -pvc
(preview continuously) and -c
(clean up) options together for latexmk
.
latexmk -pdf -pvc -c file.tex
My observation: After giving -c
option, the file gets compiled, (regeneratable) files are deleted and I am back to the command prompt.
Is it possible to achieve this?
-- Mike
latexmk
I am unable to put the -pvc
(preview continuously) and -c
(clean up) options together for latexmk
.
latexmk -pdf -pvc -c file.tex
My observation: After giving -c
option, the file gets compiled, (regeneratable) files are deleted and I am back to the command prompt.
Is it possible to achieve this?
-- Mike
latexmk
latexmk
asked Sep 29 at 17:43
Mike V.D.C.
1335
1335
bumped to the homepage by Community♦ 6 hours ago
This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.
bumped to the homepage by Community♦ 6 hours ago
This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.
I'm not quite understanding.-pvc
implies continuous compilation, which needs the auxiliary files, which means they can't be deleted. Or are you wanting the auxiliary files to be regenerated whenever you make a change? Why not just leave them around?
– Teepeemm
Sep 29 at 18:42
@Teepeemm This is precisely I want! I would like to regenerate all auxiliary files every time src file.tex is updated. and get deleted upon successful compilation. I need this as I have some restrictions on bandwidth and filesystem in terms of number of files. (Weird, huh?)
– Mike V.D.C.
Sep 30 at 6:36
add a comment |
I'm not quite understanding.-pvc
implies continuous compilation, which needs the auxiliary files, which means they can't be deleted. Or are you wanting the auxiliary files to be regenerated whenever you make a change? Why not just leave them around?
– Teepeemm
Sep 29 at 18:42
@Teepeemm This is precisely I want! I would like to regenerate all auxiliary files every time src file.tex is updated. and get deleted upon successful compilation. I need this as I have some restrictions on bandwidth and filesystem in terms of number of files. (Weird, huh?)
– Mike V.D.C.
Sep 30 at 6:36
I'm not quite understanding.
-pvc
implies continuous compilation, which needs the auxiliary files, which means they can't be deleted. Or are you wanting the auxiliary files to be regenerated whenever you make a change? Why not just leave them around?– Teepeemm
Sep 29 at 18:42
I'm not quite understanding.
-pvc
implies continuous compilation, which needs the auxiliary files, which means they can't be deleted. Or are you wanting the auxiliary files to be regenerated whenever you make a change? Why not just leave them around?– Teepeemm
Sep 29 at 18:42
@Teepeemm This is precisely I want! I would like to regenerate all auxiliary files every time src file.tex is updated. and get deleted upon successful compilation. I need this as I have some restrictions on bandwidth and filesystem in terms of number of files. (Weird, huh?)
– Mike V.D.C.
Sep 30 at 6:36
@Teepeemm This is precisely I want! I would like to regenerate all auxiliary files every time src file.tex is updated. and get deleted upon successful compilation. I need this as I have some restrictions on bandwidth and filesystem in terms of number of files. (Weird, huh?)
– Mike V.D.C.
Sep 30 at 6:36
add a comment |
1 Answer
1
active
oldest
votes
up vote
0
down vote
You can write a small shell script:
f=/tmp/$$.tmp
touch $f
src=foo.tex
src="$1";
echo -e "$src -- $fn";
while true
do
if [ ${src} -nt ${f} ];
then
echo "File modified";
latexmk -c ${src}
sleep 5;
fi;
touch ${f};
sleep 5; # This is essential.
done
Welcome to TeX.SX!
– Bobyandbob
Sep 29 at 18:26
If one has to use bash script, why uselatexmk
in that case? Just putpdflatex
, followed byrm -f
commands... I believe this can be achieved with the power oflatexmk
.
– Mike V.D.C.
Sep 29 at 18:36
I may be overlooking things, but I'm not seeing how you accomplish the-pvc
portion.
– Teepeemm
Sep 29 at 18:40
@MikeV.D.C.latexmk
can do much more than just a single rub ofpdflatex
- e.g. it will repeatedly compile the document until all the cross references, tables of contents, indexes, etc, are self-consistent, but only do the minimum number of recompiles to reach that state. (That's why it seems pointless to me to delete all the auxiliary files every time you runlatexmk
- it is just makinglatexmk
work harder for no obvious reason).
– alephzero
Sep 29 at 21:33
@Teepeemm, I suspect that @user5325 is using some *nix system (e.g. ubuntu). So the default previewer (e.g. evince on ubuntu), once opened, automatically update the document on every change. Thus achieving-pvc
.
– Mike V.D.C.
Sep 30 at 6:42
|
show 1 more comment
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
0
down vote
You can write a small shell script:
f=/tmp/$$.tmp
touch $f
src=foo.tex
src="$1";
echo -e "$src -- $fn";
while true
do
if [ ${src} -nt ${f} ];
then
echo "File modified";
latexmk -c ${src}
sleep 5;
fi;
touch ${f};
sleep 5; # This is essential.
done
Welcome to TeX.SX!
– Bobyandbob
Sep 29 at 18:26
If one has to use bash script, why uselatexmk
in that case? Just putpdflatex
, followed byrm -f
commands... I believe this can be achieved with the power oflatexmk
.
– Mike V.D.C.
Sep 29 at 18:36
I may be overlooking things, but I'm not seeing how you accomplish the-pvc
portion.
– Teepeemm
Sep 29 at 18:40
@MikeV.D.C.latexmk
can do much more than just a single rub ofpdflatex
- e.g. it will repeatedly compile the document until all the cross references, tables of contents, indexes, etc, are self-consistent, but only do the minimum number of recompiles to reach that state. (That's why it seems pointless to me to delete all the auxiliary files every time you runlatexmk
- it is just makinglatexmk
work harder for no obvious reason).
– alephzero
Sep 29 at 21:33
@Teepeemm, I suspect that @user5325 is using some *nix system (e.g. ubuntu). So the default previewer (e.g. evince on ubuntu), once opened, automatically update the document on every change. Thus achieving-pvc
.
– Mike V.D.C.
Sep 30 at 6:42
|
show 1 more comment
up vote
0
down vote
You can write a small shell script:
f=/tmp/$$.tmp
touch $f
src=foo.tex
src="$1";
echo -e "$src -- $fn";
while true
do
if [ ${src} -nt ${f} ];
then
echo "File modified";
latexmk -c ${src}
sleep 5;
fi;
touch ${f};
sleep 5; # This is essential.
done
Welcome to TeX.SX!
– Bobyandbob
Sep 29 at 18:26
If one has to use bash script, why uselatexmk
in that case? Just putpdflatex
, followed byrm -f
commands... I believe this can be achieved with the power oflatexmk
.
– Mike V.D.C.
Sep 29 at 18:36
I may be overlooking things, but I'm not seeing how you accomplish the-pvc
portion.
– Teepeemm
Sep 29 at 18:40
@MikeV.D.C.latexmk
can do much more than just a single rub ofpdflatex
- e.g. it will repeatedly compile the document until all the cross references, tables of contents, indexes, etc, are self-consistent, but only do the minimum number of recompiles to reach that state. (That's why it seems pointless to me to delete all the auxiliary files every time you runlatexmk
- it is just makinglatexmk
work harder for no obvious reason).
– alephzero
Sep 29 at 21:33
@Teepeemm, I suspect that @user5325 is using some *nix system (e.g. ubuntu). So the default previewer (e.g. evince on ubuntu), once opened, automatically update the document on every change. Thus achieving-pvc
.
– Mike V.D.C.
Sep 30 at 6:42
|
show 1 more comment
up vote
0
down vote
up vote
0
down vote
You can write a small shell script:
f=/tmp/$$.tmp
touch $f
src=foo.tex
src="$1";
echo -e "$src -- $fn";
while true
do
if [ ${src} -nt ${f} ];
then
echo "File modified";
latexmk -c ${src}
sleep 5;
fi;
touch ${f};
sleep 5; # This is essential.
done
You can write a small shell script:
f=/tmp/$$.tmp
touch $f
src=foo.tex
src="$1";
echo -e "$src -- $fn";
while true
do
if [ ${src} -nt ${f} ];
then
echo "File modified";
latexmk -c ${src}
sleep 5;
fi;
touch ${f};
sleep 5; # This is essential.
done
answered Sep 29 at 18:09
user5325
1
1
Welcome to TeX.SX!
– Bobyandbob
Sep 29 at 18:26
If one has to use bash script, why uselatexmk
in that case? Just putpdflatex
, followed byrm -f
commands... I believe this can be achieved with the power oflatexmk
.
– Mike V.D.C.
Sep 29 at 18:36
I may be overlooking things, but I'm not seeing how you accomplish the-pvc
portion.
– Teepeemm
Sep 29 at 18:40
@MikeV.D.C.latexmk
can do much more than just a single rub ofpdflatex
- e.g. it will repeatedly compile the document until all the cross references, tables of contents, indexes, etc, are self-consistent, but only do the minimum number of recompiles to reach that state. (That's why it seems pointless to me to delete all the auxiliary files every time you runlatexmk
- it is just makinglatexmk
work harder for no obvious reason).
– alephzero
Sep 29 at 21:33
@Teepeemm, I suspect that @user5325 is using some *nix system (e.g. ubuntu). So the default previewer (e.g. evince on ubuntu), once opened, automatically update the document on every change. Thus achieving-pvc
.
– Mike V.D.C.
Sep 30 at 6:42
|
show 1 more comment
Welcome to TeX.SX!
– Bobyandbob
Sep 29 at 18:26
If one has to use bash script, why uselatexmk
in that case? Just putpdflatex
, followed byrm -f
commands... I believe this can be achieved with the power oflatexmk
.
– Mike V.D.C.
Sep 29 at 18:36
I may be overlooking things, but I'm not seeing how you accomplish the-pvc
portion.
– Teepeemm
Sep 29 at 18:40
@MikeV.D.C.latexmk
can do much more than just a single rub ofpdflatex
- e.g. it will repeatedly compile the document until all the cross references, tables of contents, indexes, etc, are self-consistent, but only do the minimum number of recompiles to reach that state. (That's why it seems pointless to me to delete all the auxiliary files every time you runlatexmk
- it is just makinglatexmk
work harder for no obvious reason).
– alephzero
Sep 29 at 21:33
@Teepeemm, I suspect that @user5325 is using some *nix system (e.g. ubuntu). So the default previewer (e.g. evince on ubuntu), once opened, automatically update the document on every change. Thus achieving-pvc
.
– Mike V.D.C.
Sep 30 at 6:42
Welcome to TeX.SX!
– Bobyandbob
Sep 29 at 18:26
Welcome to TeX.SX!
– Bobyandbob
Sep 29 at 18:26
If one has to use bash script, why use
latexmk
in that case? Just put pdflatex
, followed by rm -f
commands... I believe this can be achieved with the power of latexmk
.– Mike V.D.C.
Sep 29 at 18:36
If one has to use bash script, why use
latexmk
in that case? Just put pdflatex
, followed by rm -f
commands... I believe this can be achieved with the power of latexmk
.– Mike V.D.C.
Sep 29 at 18:36
I may be overlooking things, but I'm not seeing how you accomplish the
-pvc
portion.– Teepeemm
Sep 29 at 18:40
I may be overlooking things, but I'm not seeing how you accomplish the
-pvc
portion.– Teepeemm
Sep 29 at 18:40
@MikeV.D.C.
latexmk
can do much more than just a single rub of pdflatex
- e.g. it will repeatedly compile the document until all the cross references, tables of contents, indexes, etc, are self-consistent, but only do the minimum number of recompiles to reach that state. (That's why it seems pointless to me to delete all the auxiliary files every time you run latexmk
- it is just making latexmk
work harder for no obvious reason).– alephzero
Sep 29 at 21:33
@MikeV.D.C.
latexmk
can do much more than just a single rub of pdflatex
- e.g. it will repeatedly compile the document until all the cross references, tables of contents, indexes, etc, are self-consistent, but only do the minimum number of recompiles to reach that state. (That's why it seems pointless to me to delete all the auxiliary files every time you run latexmk
- it is just making latexmk
work harder for no obvious reason).– alephzero
Sep 29 at 21:33
@Teepeemm, I suspect that @user5325 is using some *nix system (e.g. ubuntu). So the default previewer (e.g. evince on ubuntu), once opened, automatically update the document on every change. Thus achieving
-pvc
.– Mike V.D.C.
Sep 30 at 6:42
@Teepeemm, I suspect that @user5325 is using some *nix system (e.g. ubuntu). So the default previewer (e.g. evince on ubuntu), once opened, automatically update the document on every change. Thus achieving
-pvc
.– Mike V.D.C.
Sep 30 at 6:42
|
show 1 more comment
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f453108%2flatexmk-with-cleanup-and-pvc%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
I'm not quite understanding.
-pvc
implies continuous compilation, which needs the auxiliary files, which means they can't be deleted. Or are you wanting the auxiliary files to be regenerated whenever you make a change? Why not just leave them around?– Teepeemm
Sep 29 at 18:42
@Teepeemm This is precisely I want! I would like to regenerate all auxiliary files every time src file.tex is updated. and get deleted upon successful compilation. I need this as I have some restrictions on bandwidth and filesystem in terms of number of files. (Weird, huh?)
– Mike V.D.C.
Sep 30 at 6:36