Skip to content

Commit

Permalink
Pull request 1763: AG-20200-translation-script
Browse files Browse the repository at this point in the history
Merge in DNS/adguard-home from AG-20200-translation-script to master

Squashed commit of the following:

commit 3113b77
Merge: bbd784a f736d85
Author: Stanislav Chzhen <s.chzhen@adguard.com>
Date:   Tue Mar 21 17:41:08 2023 +0300

    Merge branch 'master' into AG-20200-translation-script

commit bbd784a
Author: Stanislav Chzhen <s.chzhen@adguard.com>
Date:   Tue Mar 21 13:23:48 2023 +0300

    scripts: imp code

commit 7d379ab
Merge: 4f6278a 1daabb9
Author: Stanislav Chzhen <s.chzhen@adguard.com>
Date:   Tue Mar 21 12:01:16 2023 +0300

    Merge branch 'master' into AG-20200-translation-script

commit 4f6278a
Author: Stanislav Chzhen <s.chzhen@adguard.com>
Date:   Fri Mar 17 14:27:32 2023 +0300

    scripts: imp error handling

commit 64e307a
Author: Stanislav Chzhen <s.chzhen@adguard.com>
Date:   Thu Mar 16 15:41:39 2023 +0300

    scripts: imp code

commit fe06df8
Author: Stanislav Chzhen <s.chzhen@adguard.com>
Date:   Thu Mar 16 15:23:20 2023 +0300

    scripts: add docs

commit 15d65a0
Merge: ddd3cac 9f7a582
Author: Stanislav Chzhen <s.chzhen@adguard.com>
Date:   Thu Mar 16 13:04:16 2023 +0300

    Merge branch 'master' into AG-20200-translation-script

commit ddd3cac
Author: Stanislav Chzhen <s.chzhen@adguard.com>
Date:   Thu Mar 16 13:03:11 2023 +0300

    scripts: imp code

commit 4e8ebdc
Merge: 73fedef c670644
Author: Stanislav Chzhen <s.chzhen@adguard.com>
Date:   Wed Mar 15 12:25:36 2023 +0300

    Merge branch 'master' into AG-20200-translation-script

commit 73fedef
Author: Stanislav Chzhen <s.chzhen@adguard.com>
Date:   Wed Mar 15 12:25:04 2023 +0300

    scripts: fix chlog

commit 780b0a2
Merge: ef70d19 595484e
Author: Stanislav Chzhen <s.chzhen@adguard.com>
Date:   Tue Mar 14 14:58:24 2023 +0300

    Merge branch 'master' into AG-20200-translation-script

commit ef70d19
Author: Stanislav Chzhen <s.chzhen@adguard.com>
Date:   Tue Mar 14 14:57:36 2023 +0300

    scripts: upd readme

commit e286558
Merge: cae3b76 a205352
Author: Stanislav Chzhen <s.chzhen@adguard.com>
Date:   Mon Mar 13 14:28:47 2023 +0300

    Merge branch 'master' into AG-20200-translation-script

commit cae3b76
Author: Stanislav Chzhen <s.chzhen@adguard.com>
Date:   Mon Mar 13 14:27:29 2023 +0300

    scripts: rm translations js

commit 77e2e34
Merge: 99e2382 c11a52d
Author: Stanislav Chzhen <s.chzhen@adguard.com>
Date:   Tue Mar 7 16:04:06 2023 +0300

    Merge branch 'master' into AG-20200-translation-script

commit 99e2382
Author: Stanislav Chzhen <s.chzhen@adguard.com>
Date:   Tue Mar 7 16:03:19 2023 +0300

    scripts: add translations go
  • Loading branch information
schzhn committed Mar 21, 2023
1 parent f736d85 commit c3edab4
Show file tree
Hide file tree
Showing 10 changed files with 480 additions and 1,138 deletions.
24 changes: 15 additions & 9 deletions scripts/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -178,22 +178,28 @@ manifest file templates, and helper scripts.

### Usage

* `npm install`: install dependencies. Run this first.
* `npm run locales:download`: download and save all translations.
* `npm run locales:upload`: upload the base `en` locale.
* `npm run locales:summary`: show the current locales summary.
* `npm run locales:unused`: show the list of unused strings.
* `go run main.go help`: print usage.

* `go run main.go download [-n <count>]`: download and save all translations.
`n` is optional flag where count is a number of concurrent downloads.

* `go run main.go upload`: upload the base `en` locale.

* `go run main.go summary`: show the current locales summary.

* `go run main.go unused`: show the list of unused strings.

After the download you'll find the output locales in the `client/src/__locales/`
directory.
Optional environment:
* `SLEEP_TIME`: set the sleep time between downloads for `locales:download`,
in milliseconds. The default is 250 ms.
* `UPLOAD_LANGUAGE`: set an alternative language for `upload`.
* `TWOSKY_URI`: set an alternative URL for `download` or `upload`.
* `UPLOAD_LANGUAGE`: set an alternative language for `locales:upload` to
upload.
* `TWOSKY_PROJECT_ID`: set an alternative project ID for `download` or
`upload`.
Expand Down
1 change: 1 addition & 0 deletions scripts/make/go-lint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -182,6 +182,7 @@ run_linter gocyclo --over 10\
./internal/version/\
./scripts/blocked-services/\
./scripts/vetted-filters/\
./scripts/translations/\
./main.go\
;

Expand Down
1 change: 0 additions & 1 deletion scripts/translations/.gitignore

This file was deleted.

41 changes: 0 additions & 41 deletions scripts/translations/count.js

This file was deleted.

125 changes: 0 additions & 125 deletions scripts/translations/download.js

This file was deleted.

Loading

0 comments on commit c3edab4

Please sign in to comment.