wailsapp / wailsapp/wails

[v3] How to enable internationalization for Mac apps

Open
#4,582 5 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Bug MacOS P2 question v3
Dominant language
Go
Stars
36.3k
Forks
1.9k
Avg merge
2d 11h
Merged PRs (30d)
33

Description

Description

Adding Resources/en.lproj and Resources/zh-Hans.lproj to build/darwin does not work properly for internationalized display of Mac applications

To Reproduce

example-wails

add darwin Resources dir

  create:app:bundle:
    summary: Creates an `.app` bundle
    cmds:
      - mkdir -p {{.BIN_DIR}}/{{.APP_NAME}}.app/Contents/{MacOS,Resources}
      - cp -rf build/darwin/Resources {{.BIN_DIR}}/{{.APP_NAME}}.app/Contents
      - cp build/darwin/icons.icns {{.BIN_DIR}}/{{.APP_NAME}}.app/Contents/Resources
      - cp {{.BIN_DIR}}/{{.APP_NAME}} {{.BIN_DIR}}/{{.APP_NAME}}.app/Contents/MacOS
      - cp build/darwin/Info.plist {{.BIN_DIR}}/{{.APP_NAME}}.app/Contents
Expected behaviour

Internationalized names cannot be displayed

Screenshots

No response

Attempted Fixes

No response

System Details
Wails (v3.0.0-alpha.27
)  Wails Doctor 
                                                                                                                                                                                                                                        
# System 

┌──────────────────────────────────────────────────┐
| Name          | MacOS                            |
| Version       | 15.4.1                           |
| ID            | 24E263                           |
| Branding      | Sequoia                          |
| Platform      | darwin                           |
| Architecture  | arm64                            |
| Apple Silicon | true                             |
| CPU           | Apple M2 Max                     |
| CPU 1         | Apple M2 Max                     |
| CPU 2         | Apple M2 Max                     |
| GPU           | 38 cores, Metal Support: Metal 3 |
| Memory        | 32 GB                            |
└──────────────────────────────────────────────────┘

# Build Environment 

┌─────────────────────────────────────────────────────────────────────────────────────────────────────┐
| Wails CLI      | v3.0.0-alpha.27                                                                    |
| Go Version     | go1.25.1                                                                           |
| -buildmode     | exe                                                                                |
| -compiler      | gc                                                                                 |
| CGO_CFLAGS     |                                                                                    |
| CGO_CPPFLAGS   |                                                                                    |
| CGO_CXXFLAGS   |                                                                                    |
| CGO_ENABLED    | 1                                                                                  |
| CGO_LDFLAGS    |                                                                                    |
| DefaultGODEBUG | containermaxprocs=0,decoratemappings=0,tlssha1=1,updatemaxprocs=0,x509sha256skid=0 |
| GOARCH         | arm64                                                                              |
| GOARM64        | v8.0                                                                               |
| GOOS           | darwin                                                                             |
└─────────────────────────────────────────────────────────────────────────────────────────────────────┘

# Dependencies 

┌───────────────────────────┐
| Xcode cli tools | 2409    |
| npm             | 10.2.4  |
| *NSIS           | v3.11   |
|                           |
└─ * - Optional Dependency ─┘
Additional context

No response

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the problem with the linked example-wails project and its build/darwin/Resources directory. Start by tracing the shown create:app:bundle commands and the generated .app Contents/Resources and Info.plist files. Done means localized names from en.lproj and zh-Hans.lproj display correctly in the Mac application bundle.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
build-system, desktop
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Needs clarification
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.