Add action which returns the file content in the wiki repository.

This commit is contained in:
takezoe
2013-06-16 02:09:21 +09:00
parent e5b3399127
commit 8c12e15bc5

View File

@@ -146,6 +146,15 @@ trait WikiControllerBase extends ControllerBase {
}
})
get("/:owner/:repository/wiki/_blob/*")(readableRepository {
val owner = params("owner")
val repository = params("repository")
val path = multiParams("splat").head
contentType = "application/octet-stream"
getFileContent(owner, repository, path).get
})
/**
* Constraint for the wiki page name.
*/