https://github.com/JoshuaDoes/gofuckyourself
A sanitization-based swear filter for Go.
https://github.com/JoshuaDoes/gofuckyourself
filter golang joshuadoes swear swear-filter
Last synced: 9 months ago
JSON representation
A sanitization-based swear filter for Go.
- Host: GitHub
- URL: https://github.com/JoshuaDoes/gofuckyourself
- Owner: JoshuaDoes
- License: mit
- Created: 2018-09-09T00:07:26.000Z (about 7 years ago)
- Default Branch: master
- Last Pushed: 2023-04-16T19:15:33.000Z (over 2 years ago)
- Last Synced: 2024-04-22T13:32:23.120Z (over 1 year ago)
- Topics: filter, golang, joshuadoes, swear, swear-filter
- Language: Go
- Size: 21.5 KB
- Stars: 63
- Watchers: 2
- Forks: 8
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- awesome-go-cn - gofuckyourself
- awesome-go-extra - gofuckyourself - based swear filter for Go.|48|7|3|2018-09-09T00:07:26Z|2021-06-23T18:34:01Z| (Bot Building / Sanitation)
- awesome-go - gofuckyourself - A sanitization-based swear filter for Go. (Text Processing / Sanitation)
- awesome-go - gofuckyourself - based swear filter for Go. | - | - | - | (Text Processing / HTTP Clients)
- awesome-go - gofuckyourself - A sanitization-based swear filter for Go. (Text Processing / Sanitation)
- awesome-go-plus - gofuckyourself - A sanitization-based swear filter for Go.  (Text Processing / Sanitation)
- awesome-go - gofuckyourself - A sanitization-based swear filter for Go. (Text Processing / Sanitation)
- awesome-go - gofuckyourself - A sanitization-based swear filter for Go. (Text Processing / HTTP Clients)
- awesome-go - JoshuaDoes/gofuckyourself - based swear filter for Go. ☆`68` (Text Processing / Sanitation)
- awesome-go-with-stars - gofuckyourself - A sanitization-based swear filter for Go. (Text Processing / Sanitation)
- awesome-go - gofuckyourself - A sanitization-based swear filter for Go. (Text Processing / Sanitation)
- awesome-go - gofuckyourself - A sanitization-based swear filter for Go. (Text Processing / Sanitation)
- fucking-awesome-go - gofuckyourself - A sanitization-based swear filter for Go. (Text Processing / Sanitation)
- awesome-Char - gofuckyourself - A sanitization-based swear filter for Go. (Text Processing / HTTP Clients)
- awesome-go-cn - gofuckyourself
- awesome-go - gofuckyourself - A sanitization-based swear filter for Go. (Text Processing / HTTP Clients)
- awesome-go-cn - gofuckyourself
README
# gofuckyourself
[](https://godoc.org/github.com/JoshuaDoes/gofuckyourself)
[](https://goreportcard.com/report/github.com/JoshuaDoes/gofuckyourself)
[](https://cover.run/go?tag=golang-1.10&repo=github.com%2FJoshuaDoes%2Fgofuckyourself)
A sanitization-based swear filter for Go.
# Installing
`go get github.com/JoshuaDoes/gofuckyourself`
# Example
```Go
package main
import (
"fmt"
swearfilter "github.com/JoshuaDoes/gofuckyourself"
)
var message = "This is a fûçking message with shitty swear words."
var swears = []string{"fuck", "shit"}
func main() {
filter := swearfilter.New(false, false, false, false, false, swears...)
swearFound, swearsFound, err := filter.Check(message)
fmt.Println("Swear found: ", swearFound)
fmt.Println("Swears tripped: ", swearsFound)
fmt.Println("Error: ", err)
}
```
### Output
```
> go run main.go
Swear found: true
Swears tripped: [fuck shit]
Error:
```
## License
The source code for gofuckyourself is released under the MIT License. See LICENSE for more details.
## Donations
All donations are appreciated and help me stay awake at night to work on this more. Even if it's not much, it helps a lot in the long run!
[](https://paypal.me/JoshuaDoes)