summaryrefslogtreecommitdiff
path: root/vendor/github.com/gosimple/unidecode/README.md
diff options
context:
space:
mode:
authorMitja Felicijan <mitja.felicijan@gmail.com>2024-10-25 00:47:47 +0200
committerMitja Felicijan <mitja.felicijan@gmail.com>2024-10-25 00:47:47 +0200
commitc6cc0108ca7738023b45e0eeac0fa2390532dd93 (patch)
tree36890e6cd3091bbab8efbe686cc56f467f645bfd /vendor/github.com/gosimple/unidecode/README.md
parent0130404a1dc663d4aa68d780c9bcb23a4243e68d (diff)
downloadjbmafp-master.tar.gz
Added vendor lock on depsHEADmaster
Diffstat (limited to 'vendor/github.com/gosimple/unidecode/README.md')
-rw-r--r--vendor/github.com/gosimple/unidecode/README.md58
1 files changed, 58 insertions, 0 deletions
diff --git a/vendor/github.com/gosimple/unidecode/README.md b/vendor/github.com/gosimple/unidecode/README.md
new file mode 100644
index 0000000..3f95400
--- /dev/null
+++ b/vendor/github.com/gosimple/unidecode/README.md
@@ -0,0 +1,58 @@
+# unidecode
+
+[![Go Reference](https://pkg.go.dev/badge/github.com/gosimple/unidecode.svg)](https://pkg.go.dev/github.com/gosimple/unidecode)
+[![Tests](https://github.com/gosimple/unidecode/actions/workflows/tests.yml/badge.svg)](https://github.com/gosimple/unidecode/actions/workflows/tests.yml)
+
+Unicode transliterator in Golang - Replaces non-ASCII characters with their
+ASCII approximations.
+
+Fork of https://github.com/rainycape/unidecode
+
+## Example
+
+```go
+package main
+
+import (
+ "fmt"
+
+ "github.com/gosimple/unidecode"
+)
+
+func main() {
+ decoded := unidecode.Unidecode("Łódź")
+ fmt.Println(decoded)
+ // Output: Lodz
+}
+```
+
+### Requests or bugs?
+
+<https://github.com/gosimple/unidecode/issues>
+
+## Installation
+
+```shell
+go get -u github.com/gosimple/unidecode
+```
+
+## Benchmark
+
+```shell
+go test -run=NONE -bench=. -benchmem -count=6 ./... > old.txt
+# make changes
+go test -run=NONE -bench=. -benchmem -count=6 ./... > new.txt
+
+go install golang.org/x/perf/cmd/benchstat@latest
+
+benchstat old.txt new.txt
+```
+
+## Add new characters
+
+1. Edit `table.txt` file.
+2. Rebuild `table.go` file:
+
+ ```go
+ go run ./make_table.go
+ ```