mirror of
https://github.com/hajimehoshi/ebiten.git
synced 2025-01-13 12:32:05 +01:00
Remove parseMarkdown
This commit is contained in:
parent
2737b29867
commit
be5785c1cf
16
_docs/gen.go
16
_docs/gen.go
@ -17,7 +17,6 @@
|
|||||||
package main
|
package main
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/google/go-github/github"
|
|
||||||
"html/template"
|
"html/template"
|
||||||
"io/ioutil"
|
"io/ioutil"
|
||||||
"log"
|
"log"
|
||||||
@ -46,21 +45,6 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|||||||
See the License for the specific language governing permissions and
|
See the License for the specific language governing permissions and
|
||||||
limitations under the License.`
|
limitations under the License.`
|
||||||
|
|
||||||
func parseMarkdown(path string) (string, error) {
|
|
||||||
md, err := ioutil.ReadFile(path)
|
|
||||||
if err != nil {
|
|
||||||
return "", err
|
|
||||||
}
|
|
||||||
|
|
||||||
client := github.NewClient(nil)
|
|
||||||
html, _, err := client.Markdown(string(md), nil)
|
|
||||||
if err != nil {
|
|
||||||
return "", err
|
|
||||||
}
|
|
||||||
|
|
||||||
return html, nil
|
|
||||||
}
|
|
||||||
|
|
||||||
func comment(text string) template.HTML {
|
func comment(text string) template.HTML {
|
||||||
// TODO: text should be escaped
|
// TODO: text should be escaped
|
||||||
return template.HTML("<!--" + text + "-->")
|
return template.HTML("<!--" + text + "-->")
|
||||||
|
Loading…
Reference in New Issue
Block a user