105 lines · 2.2 KB · Go
RawDownload
// Copyright 2015 The Gogs Authors. All rights reserved.// SPDX-License-Identifier: MIT package structs // SearchResults results of a successful searchtype SearchResults struct {	OK   bool          `json:"ok"`	Data []*Repository `json:"data"`} // SearchError error of a failed searchtype SearchError struct {	OK    bool   `json:"ok"`	Error string `json:"error"`} // MarkupOption markup optionstype MarkupOption struct {	// Text markup to render	//	// in: body	Text string	// Mode to render (comment, gfm, markdown, file)	//	// in: body	Mode string	// Context to render	//	// in: body	Context string	// Is it a wiki page ?	//	// in: body	Wiki bool	// File path for detecting extension in file mode	//	// in: body	FilePath string	// The current branch path where the form gets posted	//	// in: body	BranchPath string} // MarkupRender is a rendered markup document// swagger:response MarkupRendertype MarkupRender string // MarkdownOption markdown optionstype MarkdownOption struct {	// Text markdown to render	//	// in: body	Text string	// Mode to render (comment, gfm, markdown)	//	// in: body	Mode string	// Context to render	//	// in: body	Context string	// Is it a wiki page ?	//	// in: body	Wiki bool} // MarkdownRender is a rendered markdown document// swagger:response MarkdownRendertype MarkdownRender string // ServerVersion wraps the version of the servertype ServerVersion struct {	Version string `json:"version"`} // GitignoreTemplateInfo name and text of a gitignore templatetype GitignoreTemplateInfo struct {	Name   string `json:"name"`	Source string `json:"source"`} // LicensesListEntry is used for the APItype LicensesTemplateListEntry struct {	Key  string `json:"key"`	Name string `json:"name"`	URL  string `json:"url"`} // LicensesInfo contains information about a Licensetype LicenseTemplateInfo struct {	Key            string `json:"key"`	Name           string `json:"name"`	URL            string `json:"url"`	Implementation string `json:"implementation"`	Body           string `json:"body"`} // APIError is an api error with a messagetype APIError struct {	Message string `json:"message"`	URL     string `json:"url"`}