mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-26 03:11:59 +00:00
Better fix for #7551. We can now handle several dots in the file name.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@39068 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
d1b7fc972c
commit
c820e4f8e2
@ -30,8 +30,10 @@ options(encoding=ls.args[3])
|
|||||||
setwd(ls.args[4])
|
setwd(ls.args[4])
|
||||||
|
|
||||||
# this is passed as a prefix.string to tell where temporary files should go
|
# this is passed as a prefix.string to tell where temporary files should go
|
||||||
ls.pr <- gsub('\\.([^/]*)$', '-\\1', sub("\\.tex$", "", ls.args[2]))
|
# the output file without extension and without '.'
|
||||||
|
tmpout <- gsub(".", "-", sub("\\.tex$", "", basename(ls.args[2])), fixed = TRUE)
|
||||||
|
# replace
|
||||||
|
ls.pr <- paste(dirname(ls.args[2]), tmpout, sep="/")
|
||||||
|
|
||||||
# finally run sweave
|
# finally run sweave
|
||||||
Sweave(file=ls.args[1], output=ls.args[2], syntax="SweaveSyntaxNoweb", stylepath=ls.sp, prefix.string=ls.pr)
|
Sweave(file=ls.args[1], output=ls.args[2], syntax="SweaveSyntaxNoweb", stylepath=ls.sp, prefix.string=ls.pr)
|
||||||
|
Loading…
Reference in New Issue
Block a user