mirror of
https://github.com/yu-i-i/overleaf-cep.git
synced 2026-05-23 17:19:37 +02:00
Allow adding extra flags to LaTeX compiler through environment variable
This commit is contained in:
@@ -812,7 +812,7 @@ async function _getContentFromMongo(projectId) {
|
||||
|
||||
function _finaliseRequest(projectId, options, project, docs, files) {
|
||||
const resources = []
|
||||
let flags
|
||||
let flags = []
|
||||
let rootResourcePath = null
|
||||
let rootResourcePathOverride = null
|
||||
let hasMainFile = false
|
||||
@@ -881,6 +881,10 @@ function _finaliseRequest(projectId, options, project, docs, files) {
|
||||
flags = ['-file-line-error']
|
||||
}
|
||||
|
||||
if (process.env.TEX_COMPILER_EXTRA_FLAGS) {
|
||||
flags.push(...process.env.TEX_COMPILER_EXTRA_FLAGS.split(/\s+/).filter(Boolean))
|
||||
}
|
||||
|
||||
return {
|
||||
compile: {
|
||||
options: {
|
||||
|
||||
Reference in New Issue
Block a user