summaryrefslogtreecommitdiffstats
path: root/cmd
diff options
context:
space:
mode:
authorLunny Xiao <xiaolunwen@gmail.com>2017-11-07 14:33:06 +0800
committerLauris BH <lauris@nix.lv>2017-11-07 08:33:06 +0200
commit62d0a4d8829f214af4f9c00ecf8a81907d86ef06 (patch)
treec227fd240dcebde532b5ecef7d4b60a042e1f77e /cmd
parentddb75191eca30343783521c06f8706397c9260b8 (diff)
downloadgitea-62d0a4d8829f214af4f9c00ecf8a81907d86ef06.tar.gz
gitea-62d0a4d8829f214af4f9c00ecf8a81907d86ef06.zip
Add external markup render support (#2570)
* add external markup render support * bug fixed * refacotr codes and fix wrong error log * fix comments and add check to prevent leaks * add check for config file and improve the example * check file close error * use ioutil.TempFile instead uuid * correct Render -> Parser * improve warning when incorrect markup setting * fix typos
Diffstat (limited to 'cmd')
-rw-r--r--cmd/web.go3
1 files changed, 3 insertions, 0 deletions
diff --git a/cmd/web.go b/cmd/web.go
index 21f12ee167..811771aa5b 100644
--- a/cmd/web.go
+++ b/cmd/web.go
@@ -14,6 +14,7 @@ import (
"strings"
"code.gitea.io/gitea/modules/log"
+ "code.gitea.io/gitea/modules/markup/external"
"code.gitea.io/gitea/modules/setting"
"code.gitea.io/gitea/routers"
"code.gitea.io/gitea/routers/routes"
@@ -59,6 +60,8 @@ func runWeb(ctx *cli.Context) error {
routers.GlobalInit()
+ external.RegisterParsers()
+
m := routes.NewMacaron()
routes.RegisterRoutes(m)