Releases: leonelquinteros/gotext
v1.7.0
Bumping minor version due to Go language version bumping.
What's Changed
- Fix IsTranslated* functions using n directly rather than using the nth plural form by @sblinch in #95
- go embed fs with path by @llonchj in #98
New Contributors
Full Changelog: v1.6.1...v1.7.0
v1.6.1
Full Changelog: v1.6.0...v1.6.1
v1.6.0
What's Changed
- Allow locale to use a
fs.FS
by @kobergj in #68 - Runtime translation detection by @m-horky in #69
- feat: Add language getter for Locale by @taozhou-glean in #77
- Allow setting global storage by @didrocks in #80
- Fix multiline export by @didrocks in #82
- Order locations in ascii order by @didrocks in #83
- Fix io/fs File leak by @diamondburned in #79
- Add support for multiple languages by @m-horky in #73
- Revert "Add support for multiple languages" by @leonelquinteros in #84
- Remove unused dependency by @der-lyse in #86
- Fix typo in documentation by @der-lyse in #87
- Add support for multiple languages by @m-horky in #85
New Contributors
- @kobergj made their first contribution in #68
- @m-horky made their first contribution in #69
- @taozhou-glean made their first contribution in #77
- @didrocks made their first contribution in #80
- @diamondburned made their first contribution in #79
- @der-lyse made their first contribution in #86
Full Changelog: v1.5.2...v1.6.0
v1.5.2
Bump golang.org/x/text from 0.3.7 to 0.3.8
v1.5.1
Small release with minor improvements, mainly related to dependencies.
v1.5.0
Long release with small additions.
We're pretty much releasing all small changes and refactoring that have been implemented since the last release.
I think the most important addition is the CLI tool to extract translation strings into .po
files. It has been worked for a while in the master
branch, but now it's officially included (as is) in a release.
For those who wants to know the exact changes since last release, here is a diff for you: v1.4.0...1b8a993
Enjoy, contribute, create issues and send PRs!
v1.4.0
Biggest release so far!
- Introducing MO files support! Thanks to @Dexus for the implementation.
- We have changed the way to parse the plural expressions by implementing our own plural expression parser. Thanks to @Dexus again for the hard work on this! Now this package has no external dependencies, which was a goal to achieve.
- New
Translator
interface allowsLocale
objects to use any translation source backend (non-gettext). Locale
andPo
objects now can be serialized. They implement theencoding.BinaryMarshaler
andencoding.BinaryUnmarshaler
interfaces. This way they can be cached as[]byte
to avoid translation file parsing in concurrent environments.- Added support for Go Modules. Now a project using Go Modules can import this package as a module outside the GOPATH.
Relevant commits:
v1.3.1
v1.3.0
This release fixes an issue that made GetN
and GetNC
use always the "default"
context instead of looking into the package configuration.
It also includes a refactoring of the package configuration that allows to be used in multiple concurrent goroutines without having data races.
As these 2 changes may conflict with packages using it, by assuming the "default" context on the first, or by introducing deadlocks by the second, we're increasing the minor version number for this release to indicate possible backwards compatibility breaks.
Starting on this version, we now have Pull Requests and Issues templates to fill in before creating any of these to help contributors provide all necessary information.
Relevant issues fixed
- #14 GetN and GetNC don't honor domain package variable set by SetDomain()
Relevant commits
v1.2.4
Small release to include the following commit:
- Unify fmt.Sprintf behaviour on Po and Locale
This changes how the Locale object falls back when a translation is not found to behave the same as the Po object and use fmt.Sprintf
only when variables are provided.