gophi/policy.go
kim (grufwub) f3295013d9 fix use of CrLf with DOSLineEnd
Signed-off-by: kim (grufwub) <grufwub@gmail.com>
2020-04-19 20:44:14 +01:00

41 lines
1.4 KiB
Go

package main
func generateCapsTxt() []byte {
text := "CAPS"+DOSLineEnd
text += DOSLineEnd
text += "# This is an automatically generated"+DOSLineEnd
text += "# server policy file: caps.txt"+DOSLineEnd
text += DOSLineEnd
text += "CapsVersion=1"+DOSLineEnd
text += "ExpireCapsAfter=3600"+DOSLineEnd
text += DOSLineEnd
text += "PathDelimeter=/"+DOSLineEnd
text += "PathIdentity=."+DOSLineEnd
text += "PathParent=.."+DOSLineEnd
text += "PathParentDouble=FALSE"+DOSLineEnd
text += "PathEscapeCharacter=\\"
text += "PathKeepPreDelimeter=FALSE"
text += DOSLineEnd
text += "ServerSoftware=Gophor"+DOSLineEnd
text += "ServerSoftwareVersion="+GophorVersion+DOSLineEnd
text += "ServerDescription="+*ServerDescription+DOSLineEnd
text += "ServerGeolocationString="+*ServerGeoloc+DOSLineEnd
text += DOSLineEnd
text += "ServerSupportsStdinScripts=FALSE"+DOSLineEnd
text += DOSLineEnd
text += "ServerAdmin="+*ServerAdmin+DOSLineEnd
text += DOSLineEnd
text += "DefaultEncoding=ascii"+DOSLineEnd
return []byte(text)
}
func generateRobotsTxt() []byte {
text := "Usage-agent: *"+DOSLineEnd
text += "Disallow: *"+DOSLineEnd
text += DOSLineEnd
text += "Crawl-delay: 99999"+DOSLineEnd
text += DOSLineEnd
text += "# This server does not support scraping"+DOSLineEnd
return []byte(text)
}