Skip to content
This repository has been archived by the owner on Jun 8, 2019. It is now read-only.

Introduce Wiki markdown API option #42

Merged
merged 1 commit into from
Feb 24, 2017
Merged

Introduce Wiki markdown API option #42

merged 1 commit into from
Feb 24, 2017

Conversation

andrew-boyarshin
Copy link

As it is in the title.

For go-gitea/gitea#1027.

@lunny
Copy link
Member

lunny commented Feb 23, 2017

LGTM

@andrew-boyarshin
Copy link
Author

andrew-boyarshin commented Feb 23, 2017

This PR would also require documentation change. For example:

Wiki: "true"/"false", optional, false by default

Render markdown as wiki page. Influences link URLs.

@appleboy
Copy link
Member

LGTM

@@ -9,4 +9,5 @@ type MarkdownOption struct {
Text string
Mode string
Context string
Wiki string
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be a bool, not a string

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

indeed

@andrew-boyarshin
Copy link
Author

I agree, but there were problems finding documentation. How can I be sure without docs that bind can bind to non-string fields? Will change.

@lunny
Copy link
Member

lunny commented Feb 24, 2017

@andrew-boyarshin what bind?

@andrew-boyarshin
Copy link
Author

andrew-boyarshin commented Feb 24, 2017

@lunny go-macaron one, the one which binds JSON GET request to api.MarkdownOption structure. go-macaron/binding.Bind. Called in RegisterRoutes in routers/api/v1/api.go.

Amended with string to bool change.

Signed-off-by: Andrew Boyarshin <andrew.boyarshin@gmail.com>
@andrew-boyarshin
Copy link
Author

@bkcsoft time to remove change request?

Pending merge.

@tboerger
Copy link
Member

LGTM

@lunny lunny merged commit 5771842 into go-gitea:master Feb 24, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants