Skip to content

Commit 0da2760

Browse files
authored
Update CONTRIBUTING.md to clarify translation contribution process (#4806)
2 parents 26db25b + c4a684c commit 0da2760

File tree

1 file changed

+15
-1
lines changed

1 file changed

+15
-1
lines changed

CONTRIBUTING.md

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -118,10 +118,24 @@ Lazygit supports [Nerd Fonts](https://www.nerdfonts.com) to render certain icons
118118

119119
## Internationalisation
120120

121-
Boy that's a hard word to spell. Anyway, lazygit is translated into several languages within the pkg/i18n package. If you need to render text to the user, you should add a new field to the TranslationSet struct in `pkg/i18n/english.go` and add the actual content within the `EnglishTranslationSet()` method in the same file. Then you can access via `gui.Tr.YourNewText` (or `self.c.Tr.YourNewText`, etc). Although it is appreciated if you translate the text into other languages, it's not expected of you (google translate will likely do a bad job anyway!).
121+
Boy that's a hard word to spell. Anyway, lazygit is translated into several languages within the pkg/i18n package.
122+
123+
### For developers adding new text
124+
125+
If you need to render text to the user, you should add a new field to the TranslationSet struct in `pkg/i18n/english.go` and add the actual content within the `EnglishTranslationSet()` method in the same file. Then you can access via `gui.Tr.YourNewText` (or `self.c.Tr.YourNewText`, etc).
122126

123127
Note, we use 'Sentence case' for everything (so no 'Title Case' or 'whatever-it's-called-when-there's-no-capital-letters-case')
124128

129+
### For translators
130+
131+
Lazygit translations are managed through [Crowdin](https://crowdin.com/project/lazygit/). If you'd like to contribute translations:
132+
133+
1. Join the Crowdin project at https://crowdin.com/project/lazygit/
134+
2. Select your target language and help translate missing strings
135+
3. The translation files in `pkg/i18n/translations/` are managed by the maintainers - please don't edit them directly
136+
137+
For detailed information about the translation process, including how maintainers sync translations, see `pkg/i18n/translations/README.md`.
138+
125139
## Debugging
126140

127141
The easiest way to debug lazygit is to have two terminal tabs open at once: one for running lazygit (via `go run main.go -debug` in the project root) and one for viewing lazygit's logs (which can be done via `go run main.go --logs` or just `lazygit --logs`).

0 commit comments

Comments
 (0)