Summary: | run-safari should support launching with custom language and locale | ||||||||
---|---|---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | BJ Burg <bburg> | ||||||
Component: | Tools / Tests | Assignee: | BJ Burg <bburg> | ||||||
Status: | RESOLVED FIXED | ||||||||
Severity: | Normal | CC: | ap, bburg, buildbot, commit-queue, dbates, joepeck, lforschler, rmondello | ||||||
Priority: | P2 | ||||||||
Version: | WebKit Nightly Build | ||||||||
Hardware: | Unspecified | ||||||||
OS: | Unspecified | ||||||||
Attachments: |
|
Description
BJ Burg
2017-04-02 15:41:13 PDT
With system Safari and WebKit, this can be achieved to some degree of fidelity with command line options: /Applications/Safari.app/Contents/MacOS/Safari -AppleLanguages '(fr)' -AppleLocale 'fr_FR' However, locally built WebKit does not have resources other than English, so overriding language would be no-op for most part. Overriding locale may be more useful, but I'm not sure if we inherit AppleLocale override to WebContent process. Created attachment 306094 [details]
Patch
Comment on attachment 306094 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=306094&action=review OK. I'm still unsure if this won't cause more confusion than good though. > Tools/Scripts/webkitdirs.pm:-2179 > - -g|--guard-malloc Enable Guard Malloc (OS X only) Surely this still doesn't work on Linux or Windows. > Tools/Scripts/webkitdirs.pm:2180 > + --lang=LANGUAGE Use a specific language instead of system language. Why abbreviate? > Tools/Scripts/webkitdirs.pm:2182 > + --locale=LOCALE Useg a specific locale instead of the system region. Typo: Useg. Also, these won't work on Linux either. (In reply to Alexey Proskuryakov from comment #3) > Comment on attachment 306094 [details] > Patch > > View in context: > https://bugs.webkit.org/attachment.cgi?id=306094&action=review > > OK. I'm still unsure if this won't cause more confusion than good though. > > > Tools/Scripts/webkitdirs.pm:-2179 > > - -g|--guard-malloc Enable Guard Malloc (OS X only) > > Surely this still doesn't work on Linux or Windows. > > > Tools/Scripts/webkitdirs.pm:2180 > > + --lang=LANGUAGE Use a specific language instead of system language. > > Why abbreviate? It matches the LANG environment variable. And since it's unambiguous, when type more than necessary? > > Tools/Scripts/webkitdirs.pm:2182 > > + --locale=LOCALE Useg a specific locale instead of the system region. > > Typo: Useg. Ooops. > > Also, these won't work on Linux either. I'll add a header back to state that these are specific to macOS. Created attachment 306097 [details]
For Landing
Comment on attachment 306097 [details] For Landing Clearing flags on attachment: 306097 Committed r214835: <http://trac.webkit.org/changeset/214835> All reviewed patches have been landed. Closing bug. |