mirror of
https://github.com/overleaf/overleaf.git
synced 2024-11-21 20:47:08 -05:00
Merge branch 'i18n'
Conflicts: app/coffee/infrastructure/Server.coffee app/views/project/list.jade package.json
This commit is contained in:
commit
39173fe583
5 changed files with 10 additions and 1 deletions
|
@ -9,6 +9,7 @@ Server = require("./app/js/infrastructure/Server")
|
|||
BackgroundTasks = require("./app/js/infrastructure/BackgroundTasks")
|
||||
Errors = require "./app/js/errors"
|
||||
|
||||
|
||||
argv = require("optimist")
|
||||
.options("user", {alias : "u", description : "Run the server with permissions of the specified user"})
|
||||
.options("group", {alias : "g", description : "Run the server with permissions of the specified group"})
|
||||
|
|
|
@ -49,6 +49,10 @@ module.exports = (app)->
|
|||
res.locals.settings = Settings
|
||||
next()
|
||||
|
||||
app.use (req, res, next)->
|
||||
res.locals.translate = req.i18n.translate
|
||||
next()
|
||||
|
||||
app.use (req, res, next)->
|
||||
res.locals.getSiteHost = ->
|
||||
Settings.siteUrl.substring(Settings.siteUrl.indexOf("//")+2)
|
||||
|
|
|
@ -18,6 +18,7 @@ oneDayInMilliseconds = 86400000
|
|||
ReferalConnect = require('../Features/Referal/ReferalConnect')
|
||||
RedirectManager = require("./RedirectManager")
|
||||
OldAssetProxy = require("./OldAssetProxy")
|
||||
translations = require "translations-sharelatex"
|
||||
|
||||
metrics.mongodb.monitor(Path.resolve(__dirname + "/../../../node_modules/mongojs/node_modules/mongodb"), logger)
|
||||
metrics.mongodb.monitor(Path.resolve(__dirname + "/../../../node_modules/mongoose/node_modules/mongodb"), logger)
|
||||
|
@ -46,6 +47,8 @@ app.configure () ->
|
|||
app.set 'views', __dirname + '/../../views'
|
||||
app.set 'view engine', 'jade'
|
||||
app.use express.bodyParser(uploadDir: Settings.path.uploadFolder)
|
||||
app.use express.bodyParser(uploadDir: __dirname + "/../../../data/uploads")
|
||||
app.use translations.expressMiddlewear
|
||||
app.use cookieParser
|
||||
app.use express.session
|
||||
proxy: Settings.behindProxy
|
||||
|
|
|
@ -24,4 +24,4 @@ block content
|
|||
.col-md-10.col-xs-9
|
||||
include ./list/project-list
|
||||
|
||||
include ./list/modals
|
||||
include ./list/modals
|
|
@ -25,6 +25,7 @@
|
|||
"settings-sharelatex": "git+https://github.com/sharelatex/settings-sharelatex.git#master",
|
||||
"logger-sharelatex": "git+https://github.com/sharelatex/logger-sharelatex.git#master",
|
||||
"metrics-sharelatex": "git+https://github.com/sharelatex/metrics-sharelatex.git#master",
|
||||
"translations-sharelatex": "git+https://github.com/sharelatex/translations-sharelatex.git#master",
|
||||
"soa-req-id": "git+https://github.com/sharelatex/soa-req-id.git#master",
|
||||
"fairy": "0.0.2",
|
||||
"node-uuid": "1.4.1",
|
||||
|
|
Loading…
Reference in a new issue